Preheat your oven to 350°F (175°C).
In a large skillet, heat the olive oil over medium heat. Add the chopped onion and sauté for about 3 minutes until translucent.
Add the sliced mushrooms and minced garlic to the skillet. Cook for an additional 5-7 minutes until the mushrooms are tender and any liquid has evaporated.
Stir in the dried thyme, salt, and black pepper. Remove from heat and let cool slightly.
In a large bowl, combine the cooked rice, shredded cheddar cheese, sour cream, and milk. Mix well.
Add the mushroom mixture to the rice mixture and stir until fully combined.
Transfer the mixture to a greased 9x13 inch baking dish.
In a small bowl, mix the breadcrumbs and grated Parmesan cheese. Sprinkle this mixture evenly over the casserole.
Bake in the preheated oven for 25-30 minutes, or until the top is golden brown and bubbly.
Remove from the oven and let it cool for 5 minutes before serving.