Add the garlic, shallots, and mushrooms and continue to cook, tossing occasionally, until the mushrooms begin to soften and the shallots are tender, about 4 minutes.
Reduce the heat to medium. Add the baby spinach and cook, gently tossing, until just wilted, about 2 minutes.
Add the white wine and cook until reduced by half, about 2 minutes.
Add the orzo and toss to combine. Add the broth, lemon zest, lemon juice, salt, and ricotta cheese and stir until well combined. Bring to a simmer and add the cooked chicken back into the skillet. Toss until well combined then spread the contents of the skillet into a single layer. Sprinkle the top with the mozzarella.
Transfer to the oven and bake until the orzo is cooked through and tender and the cheese and brown and bubbly, about 15 minutes. Remove from the oven and let rest for 3 to 5 minutes to allow the sauce to settle and thicken even further.