Heat olive oil in a large skillet over medium heat. Sauté the onion and green onions until they turn translucent, about 3–4 minutes.
Add the garlic and cook for another minute until fragrant. Stir in the spinach and cook until wilted (if using fresh) or until excess water evaporates (if using frozen). Remove from heat and let it cool slightly.
In a large bowl, combine the cooked spinach mixture, parsley, dill, mint (if using), and crumbled feta cheese. Mix well. Add the beaten eggs, and season the mixture with salt and pepper to taste. Stir until evenly combined.
Unroll the phyllo dough and keep it covered with a damp kitchen towel to prevent it from drying out. Phyllo dough can be delicate, so work quickly but carefully.
Option 1: Casserole Style
Brush a 9×13-inch baking dish with melted butter. Layer a sheet of phyllo dough in the dish and brush it with butter. Repeat this process, layering and buttering 8–10 sheets. Spread the spinach and feta filling evenly over the phyllo.
Continue layering and buttering another 8–10 sheets of phyllo on top of the filling. Tuck in the edges to seal. Score the top layer into squares or diamonds using a sharp knife. Bake for 40–50 minutes or until golden brown 375°F (190°C).
Option 2: Spanakopita Rolls
Lay one sheet of phyllo on a flat surface. Brush it lightly with butter and place another sheet on top. Spoon 2–3 tablespoons of filling along one edge of the phyllo. Roll the phyllo tightly into a log, tucking in the edges as you go. Brush the outside with butter. Place the rolls on a lined baking sheet and bake for 20–25 minutes or until golden brown. 375°F (190°C).
Option 3: Spanakopita Bites
Cut phyllo sheets into strips (about 3 inches wide). Spoon 1 tablespoon of filling at one end of the strip. Fold the phyllo over the filling into a triangle, continuing to fold like a flag until the strip is fully wrapped. Brush the outside with butter and place on a lined baking sheet. Bake for 15–20 minutes or until golden and crisp 375°F (190°C).