I don't know really, but this is something that I have thought of in the past. Some Ghost Pokemon I just feel are Ghost typed because they are a little eerie such as Banette, Gengar, and Sableye, while some do appear to be actual ghosts such as Yamask whose Pokedex entry states:
These Pokémon arose from the spirits of people interred in graves. Each retains memories of its former life.
So I definitely think some are actual ghosts turned into Pokemon, but not all Ghost Pokemon are actual "ghosts" of former lives. That said, I don't know if other ghosts actually exist in the Pokemon world or if they are all classified as Pokemon.