Preheat oven to 375°F. Line a 9-inch pie dish with crust, or grease well for a crustless version.
Heat olive oil in a skillet over medium heat. Sauté mushrooms and onion for 7–8 minutes, until all liquid has cooked off.
Add garlic and cook 30 seconds. Add spinach in handfuls, stirring until fully wilted, about 2–3 minutes.
Remove from heat and let the vegetable mixture cool for 5 minutes.
In a bowl, whisk eggs and milk until pale and slightly foamy.
Whisk in salt, pepper, and nutmeg.
Fold cooled vegetables and cheese into the egg mixture.
Pour filling into the prepared crust or dish.
Bake 35–40 minutes, until edges are set and the center barely wobbles.
Rest 10–15 minutes on a cooling rack before slicing.