Rinse the rice until the water runs clear.
In a pot, combine the rice, coconut milk, water, thyme, onion, garlic, salt, and pepper.
Bring the mixture to a boil, then reduce heat to low, cover, and simmer for 20-25 minutes, or until the rice is tender and the liquid is absorbed.
If using ¾ cup of peas, add them in the last 5 minutes of cooking. If using ½ cup, add them in the last 10 minutes.
Fluff the rice with a fork and serve hot.
