What materials were used to make castles?

Usually from stone, but early motte and baily forts were made of wood. Some fortresses in Eastern Europe were made of brick, since stone is scarce there.