Kheer is fine as an occasional treat, but make sure to walk for 15-20 minutes after eating sweet things to manage your blood sugar. Of course, only do light walking if your doctor has allowed physical activity.
I had major sweet cravings in my last trimester and my mom made me delicious rice kheer with lots of almonds. It's perfectly safe and comforting, just don't overeat it.
Homemade kheer is actually a great way to get some calcium and energy from milk and rice. Just make it with less sugar or use jaggery instead, and enjoy a small bowl ghar pe.
My doctor said homemade kheer is safe and healthy in moderation because of the milk and dry fruits. However, we should avoid outside sweets and not eat too much sugar to prevent gestational diabetes.