“It is not born and it never dies. Unborn, lasting, ancient, it is not killed when the body is killed.”
Krishna is speaking of the self that lives in the body. In the Gita, that self doesn't end when a life does.
A grandparent, a friend, a pet. The Gita opens with Arjuna already grieving, and Krishna's first long teaching is about death and what lasts.

“It is not born and it never dies. Unborn, lasting, ancient, it is not killed when the body is killed.”
Krishna is speaking of the self that lives in the body. In the Gita, that self doesn't end when a life does.
“As a person throws off worn-out clothes and puts on new ones, the one who lives in the body leaves worn-out bodies and enters new ones.”
In the Gita, death is a change of clothes rather than an ending. Many readers find comfort here; others read it as a picture of how life goes on.
“For whatever is born, death is certain, and for whatever dies, birth is certain. So don't grieve over what can't be avoided.”
Krishna doesn't tell Arjuna not to feel. He reminds him that loss is part of every life, and that life still asks something of him.
The Gita begins with grief. Before a single arrow flies, Arjuna is mourning the people he loves on the other side: teachers, cousins, his great-uncle Bhishma. Chapter 1 ends with him sinking down in his chariot, “his mind overborne by grief” (1.47). Krishna's first long teaching, in chapter 2, is his answer to that grief.
That answer is about what lasts. In the Gita, the self that lives in the body is never born and never dies (2.20), and bodies are put down like worn-out clothes (2.22). It is a religious teaching, and people hold it in different ways. Some find great comfort in it. Others take something simpler from it: the people we love leave far more behind than a body.
Krishna also says, plainly, that every life ends (2.27). That doesn't make grief wrong. Arjuna grieves, and Krishna doesn't send him away; he stays and talks with him for seventeen chapters. Loss is part of every life, and life still asks something of us. Both are true at once.
As a man, casting off worn-out garments, taketh new ones…Bhagavad Gita 2.22, Annie Besant's translation (1922)