The Entity was a cosmic being from an alternate timeline. In this divergent timeline, the Evolutionary War ended in the detonation of the High Evolutionary's Genetic Bomb. The result was that all humanity (and mutantkind) underwent a rapid process of evolution into higher beings.
The former mutants and superbeings, whose genes had already been greater than those of normal humans, became extremely powerful beings known as the Godlike Ones. The Godlike Ones saw their destiny in space, and joined as a collective- along with the Inhumans and Eternals- into one mass energy force, directed primarily by Wolverine.
Driven by some unknown compulsion, the Godlike Ones defeated or destroyed many of the cosmic powers, eventually facing Mistress Death herself- and assimilating her into their ever-evolving form. The Death-Godlike Ones amalgam faced omnipotent Eternity, assimilating him as well. The resulting merged being became known as the Entity.
Having realized its destiny, the Entity left its universe- rejecting the one who'd started the entire process, the High Evolutionary, as they did so- and proceeded to create a new universe in an empty void. Entity fissioned back into Death and Eternity, and the Godlike Ones ceased to be in this monumental exercise of their power. Without the Entity, the original timeline's universe collapsed in on itself, to begin anew.
Why they chose Wolverine as the leader over any of the more experienced or powerful members of the group is unknown- perhaps he possessed the right mix of experience and aggression.