When Dave Lister and Kryten were judged by The Inquisitor, they suffered the fate of the unworthy. They were surgically removed from time and replaced by alternate versions of themselves, "the sperms that never made it". This version of Lister took his place as the last human alive and lived a similar life to the original.
He appeared physically similar to the original, sharing the same basic genetics, but was distinctly a different person. He acted identically to his counterpart, including their attitude towards Rimmer, and dressed in the same outfit.
When the original Lister and Kryten escaped The Inquisitor, they triggered a security alert because their palmprints could not be recognised by the doors. The crew of Red Dwarf arrived, including the new versions of Lister and Kryten. They were people who had never been given the chance of life before The Inquisitor intervened.
As they took the intruders to the brig, the crew was attacked by The Inquisitor, who was trying to complete his work by destroying the originals. He instead managed to make the new versions of Lister and Kryten die in an explosion. This enabled the originals to get through the security doors by using the dead duplicate's severed hand. Kryten found the idea quite nauseating.
The alternate timeline was reset to normal later, when Lister tricked The Inquisitor into erasing his own existence. This meant that the alternate Lister had never existed, but his hand remained long enough for Lister to make one last joke in bad taste. ("The Inquisitor")