Hi Amizhoyogi,
Welcome to the forum. It sounds like you have had too much moisture. I know mushrooms like it moist and dark.
Does your garden get at least 8 hours of sunlight a day? Have you had excessive rain? I know in Northern Illinois, we have had a lot and I'm sure it all moves easterly from here. Mushrooms have been
growing in my grass recently. As for the flies, are you adding anything to your garden? If your throwing in food (like apple cores,
potato peels etc) the flies will be come around. If your adding compost, try more brown like brown leaves, twigs, straw, coffee grounds. Weezie (a very wise and knowledgable gardner) taught me about balancing browns and greens. I had too much green in my compost bin and it smelled like a pig penn and flies were abuzzing everywhere! I've added brown leaves (from last fall) each time I add greens and the flies and smell are gone! Well, good luck, I hope I've helped. Give more details of what you've been doing and someone on this forum will give you the answers.
--Bunny T.