Henry is actually seeing Lila as Athena in a flashback. Additionally, the flashbacks coming from Sam of he and Lila are constructed by Henry.
Henry was in a dream-like state throughout the movie. In dreams, the mind can extract a myriad of people and can often pull from the subconscious. Our subconscious can conjure people from random events in our life we come in contact with while awake.
Henry's dreams are taking reality and twisting it into a new perspective. **Henry's new perspective is that Sam's dreams are a way for Henry's mind to solve or make sense of a real situation featuring Sam. The audience is shown this through Sam's "eyes", but through Henry's perspective.
When a person dies, their brain can still "fire" neurons. This can cause hallucinations, clarity or seeing flashes of light that can trigger a random, non-eventful memory.
Henry's brain can still produce memories, even though he is considered legally dead. He is simply producing these memories through Sam.