Sounds like you handled it really well - whether or not the child's grandma was a Christian, the child can still definitely pray to God for comfort.
Now, if she asked you flat-out, "Is my grandma in heaven now?" then pastordavidd's comment is perfect, too, IMHO!