Lay out cod fillets. Spread thin layer of cream cheese onto each one. Top with a layer of pine nuts and half the chopped garlic, a layer of mushrooms, a layer of chopped onions, a layer of baby spinach and finally a layer of Cheddar cheese-use half the cheese.
Bake in the preheated oven for 15 minutes.
Add another layer of the rest of the cheese and bake for further 5 minutes. Mix together the remaining chopped garlic, the breadcrumbs, dried herbs, and Parmesan cheese. Continue to bake until the top is browned, about 1 more minute. Serve with sliced lemon.