At least 24 people have died and many others are missing in Nigeria after a boat carrying people to a funeral capsized and sank.