Select sauté on the instant pot and adjust to normal.
Add oil to the pot.
When the oil is hot, add cloves, bay leaves, cinnamon stick, black and green cardamom pods, caraway seeds, and asafoetida.
When the caraway seeds splutter add the mushrooms.
Sauté the mushrooms for about 2 minutes. Stir.
Add water, ground fennel, ground ginger, and salt. Stir.
Make sure nothing is stuck to the bottom of the pot and scrape the bottom of the pot well.
Secure the lid on the pot and close the pressure-release valve.
Select manual and cook at high pressure for 4 minutes.
When cooking is complete, use quick pressure release to depressurize.
Open the lid.
Select sauté and add the whisked yogurt mixed with rice flour slowly (one spoon at a time) to the pot mixing it continuously. This step is key. Add one large spoon of yogurt/rice flour mix and mix it in the gravy for about a minute. Then another spoon and stir again for up-to a minute. Keep doing this until you run out of the yogurt/rice flour mix. The continual mixing will prevent curdling of the yogurt.
When you are done adding all the yogurt mix, add garam masala and dried fenugreek leaves. Stir and let it sauté for about 8 to 10 minutes until the gravy thickens. Yakhni has a lot of gravy but the yogurt will thicken it. Keep stirring occasionally.
Press cancel when the required consistency for the yakhni is reached. It should take between 3 to 4 minutes of sautéing with the yogurt mix.
Transfer to a serving bowl. Discard the bay leaves.