Preheat the oven to 375°F (190°C).
In a large skillet, heat olive oil over medium heat. Add chopped onion and garlic, sautéing for 3-4 minutes until translucent.
Add chopped spinach and cook for 2-3 minutes until wilted. Remove from heat.
In a mixing bowl, combine the cooked spinach mixture, crumbled feta, eggs, nutmeg, salt, and pepper. Mix well.
Lay out one sheet of phyllo dough on a clean surface. Lightly brush with melted butter. Layer with another phyllo sheet and repeat until four sheets are layered.
Place the phyllo stack into a baking dish and spread the spinach and feta filling evenly over it.
Repeat layering with the remaining four phyllo sheets, brushing each with butter.
Tuck the edges to neatly seal the filling and brush the top with extra butter.
Bake for 20-25 minutes until golden brown and crispy.
Let cool for a couple of minutes before slicing.