If using Basmati rice, soak in water for about 30 minutes. Drain.
Wash the rice in tap water, until the water turn clear.
Chop the onion and add to the pot. Heat on medium heat, until turn transparent.
Turn the heat to low, add the rice (without water) and mix.
Mix in spices. If using plain water as liquid, add a bit more salt.
Add liquid, and mix. Cover.
Turn up the heat and bring to very strong boil.
Turn down the heat to the lowest level and cook for 15 minutes. Try not to open the lid.
Check if all the liquid is gone. If not, cover and wait another 5 minutes.