Make the filling: heat the ghee in a pan, add the coconut and jaggery and cook on low heat for 4 to 5 minutes, stirring, until the jaggery melts and the mixture comes together and dries slightly. It should be moist, not runny. Take off the heat, stir in the cardamom, poppy seeds and nuts, and cool completely.
Make the ukad: bring the water (and milk, if using) to a rolling boil with the salt and 1 teaspoon of ghee. Lower the heat, add all the rice flour at once and stir quickly and firmly for a minute until it forms one rough mass.
Take the pan off the heat, cover and rest the dough for 10 minutes — this steaming is what makes it pliable.
While still warm, tip the dough onto a plate, grease your palms with ghee and knead for 3 to 4 minutes until completely smooth and soft, like play-dough. Cover with a damp cloth so it does not dry out.
Divide the dough into 10 to 11 lemon-sized balls. Grease your palms, flatten one ball into a 3-inch cup with your fingers, keeping the edges thinner than the base.
Place about a tablespoon of filling in the centre. With thumb and forefinger, pinch small pleats all around the edge (aim for 7 to 9), then bring them together at the top and twist gently to seal into the classic modak peak. Repeat with the rest.
Steam the modak in a greased steamer or idli stand over boiling water for 10 to 12 minutes, until the shells look glossy and feel firm and non-sticky to the touch.
Rest 2 minutes, then lift them out gently. Serve warm with a drizzle of pure ghee melted over the top.