Hello, 5th grade children ! Here it goes… the eighth Enigma !

Why kitchens were built separated from the castle in Middle Ages?