01 - Preheat oven to 400°F.
02 - In a large pot, cover potatoes with cold salted water. Bring to a boil and cook until fork-tender, about 15–20 minutes. Drain and return to pot.
03 - Add milk, butter, Parmesan (if using), salt, and pepper to the potatoes. Mash until smooth and creamy. Set aside.
04 - For the filling, heat olive oil and butter in a large skillet over medium heat. Add leeks and sauté until soft, about 5 minutes. Add garlic and cook for another minute.
05 - Stir in mushrooms, carrots, and celery. Sauté until vegetables are softened and mushrooms release their liquid, about 8–10 minutes.
06 - Add thyme and rosemary. Sprinkle flour over the vegetables and cook, stirring, for 2 minutes.
07 - Gradually stir in vegetable broth, scraping any browned bits from the pan. Add cream and Dijon mustard. Simmer for 5 minutes, until thickened.
08 - Stir in peas and season generously with salt and pepper. Remove from heat.
09 - Transfer the filling to a 2-quart baking dish. Spread mashed potatoes evenly over the top. Use a fork to create ridges for extra crispiness.
10 - Bake for 25 minutes, or until the top is golden brown and the filling is bubbling. For a crispier top, broil for an additional 2–3 minutes.
11 - Let rest for 10 minutes before serving.