A twelfth-century castle was not just a defensible fortress but a home for a family, the family of the castellan (the lord of the castle). A castellan needed a wife, who ran most things that were not directly involved in warfare: making sure there was enough food, enough firewood, enough clothing and blankets for everybody, and supervising the servants.
The lady of the castle wore the castle keys on her belt, including the keys to the treasury and to the spice chest (sometimes even more valuable). She taught both her sons and her daughters reading and simple arithmetic. The boys would usually go off for training and education elsewhere by the time they were eight or so, but the girls would run behind their mother, learning castle management, because it was likely (or so they hoped!) that they would be married in their teens and immediately start managing a castle themselves.
There were few women in a castle, the lady, some women who attended her, and her daughters. Most of the people living in the castle were male, including the cooks, as well as of course the knights (for more on knights, click here). The lady of the castle bossed them all. She could even take over defense of the castle if her husband were away.
Symbolically the whole castle was one big family. The great hall was the center of castle life, and here the castellan and his lady had their bed. It had curtains to give them at least some privacy, but most of the single men in the castle also slept in the great hall, on mats on the floor around the lord's bed. These were taken up during the day. The only private chambers were for the women, although there might also be one set aside for a visiting dignitary.