Preheat the oven to 350ºF. Finely dice the onion and mince the garlic. Add the butter, onions, and garlic to a large pot and sauté over medium heat until the onions are soft and transparent.
While the onions and garlic are sautéing, Slice the carrots and dice the celery. Add the carrots and celery to the pot and continue to sauté.
While the carrots and celery are sautéing, wash and chop the mushrooms. Add the mushrooms to the pot along with the salt, pepper, thyme, and sage. Continue to sauté until the mushrooms have turned brown and completely wilted.
Add the flour to the pot and continue to stir and cook for about 2-3 minutes more, or until the flour coats the bottom of the pot and begins to turn a light golden color. Whisk in the vegetable broth, making sure all the flour dissolves from the bottom of the pot. The mixture should thicken fairly quickly.
Once thickened, whisk in the milk and allow it to come up to a simmer again. Once simmering, turn the heat off, taste, and add more salt or pepper if needed. You want the sauce to be slightly on the salty side so that the flavor doesn’t dilute too much once the rice is added.
Stir the cooked rice into the pot with the sauce and vegetables. Transfer everything to a 2 to 3 quart casserole dish and top with the fried onions. Bake the casserole in the preheated 350ºF oven for 25-30 minutes, or until the sauce is bubbling up around the edges and the fried onions have turned deep golden brown. Serve hot.