They didn't. It's just their way of showing sympathy.
The OP may not find the prayer itself practical, as indeed many on the planet mightn't, but the expression doesn't assume so. Common secular expressions like "Sending good thoughts" or "I feel you" are just immaterial and seemingly ineffectual but similarly get across the point that someone has slowed down long enough to show care.
It's really not a big deal. I understand what they meant. I just think the secular variety of expression is preferable to (some) who have lost someone. Religions deal with the afterlife in different ways, and so it could be seen as someone else making "judgemental" assumptions.
Devil's (heh) advocate: the prayer itself matters and is a nice thought, but mentioning the recipient of the prayer makes it a soft pitch, which some might reasonably find unwelcome or awkward.
I think it can vary depending on denomination but within the belief of the trinity, it is one god in the form of three persons (father, son, holy spirit). I am certainly no theologian, though, so take that with a grain of salt.
The OP may not find the prayer itself practical, as indeed many on the planet mightn't, but the expression doesn't assume so. Common secular expressions like "Sending good thoughts" or "I feel you" are just immaterial and seemingly ineffectual but similarly get across the point that someone has slowed down long enough to show care.