Answer: Yes. This language from the McKinney-Vento Act applies:
“The choice regarding placement shall be made regardless of whether the child or youth lives with the homeless parents or has been temporarily placed elsewhere.” 42 USC 11432(g)(3)(F).
It sounds like the mother has placed the child with her mother due to homelessness. That qualifies as McKinney-Vento eligible. You could speak with the grandmother to ask for more information about the circumstances, as well. You also could revisit the situation at the beginning of the next school year, to see if it looks like they will be staying with the grandmother on a more permanent basis, if the custody is more formalized, etc.