Another explanation is that the mistakes of perception, logic and memory that cause people to believe in ghosts are inherit to the human experience and therefore have been around as long as humans. Some people still believe the world is flat, a theory that has been around a long time, does it's age give it any sort of validity?
I am not knocking the observation, only the conclusion. I also find it interesting as to why ghost stories persist. I mean after all, they are all pretty similar and transcend era, culture, location, upbringing, ect. These people are not just inventing pink unicorns out of the air, they are all having a similar experience. There must be something to it.
What I have come to believe is that something is simply mistakes. There are too many things going on to explain them all, hallucinations, illusions, trickery, mis-perceptions, bias, ect, but they all amount to mistakes. The human brain is actually very adept at fooling itself. It's the only explanation I have found to reconcile the contrast between the sheer number of reported experiences and research done on the subject and the complete and utter lack of evidence.
If you wish to explore in more detail some of these mistakes or individual cases id be happy to.