It is traditional for some religious groups to organize prayers for their dead members. Some relatives of the deceased usually carry the corpse to the place the late person used to worship for prayers.
Others offer prayers for the repose of the soul of the dead before internment.
Even after burial, some observe 8 days, 40 days, a year prayers etc for God to forgive the sins of the departed one and grant him or her eternal rest.
Even some religious adherents who don’t believe in praying for the dead would be quick to type RIP to show their love.
Do people’s prayers really avail after death?
Will People’s Prayers Work For Me After My Death? – Religion – Nigeria (nairaland.com)