So you have a pair of Arch Enemies: a hero and a villain. And then...the villain gets interested in the hero.
The hero and villain are very similar to each other, and both grow aware of that fact. But they have different reactions. While the villain genuinely wants to take the hero under his or her wing, the hero is opposed to any friendly interaction—but may fear the villain has a point. The kind of obsessive behavior and mind games this generates on both ends is a prime source of Foe Yay.
If the hero and the enemy do end up becoming mentor and student, the ensuing relationship can range from the worst kind of Training from Hell to a downright parental role. Both will still probably end up odd. And it'll end badly for at least one of them.
The Hero will usually consider The Mentor to be their Arch-Enemy and be very personally devoted to taking them down; The Mentor character is typically more amused by this than anything, and may take the role of a StealthEvil Mentor. Foe Yay may lead to a Mind Game Ship, a Mentor Ship, or both.
Related to We Can Rule Together, but rather than offering a position, offers a study period. Note that this requires a mentoring role—Worthy Opponent offering a team-up doesn't cut it.
Gauron/Sousuke in Full Metal Panic. The first time Gauron saw Sousuke, Sousuke was acting like a Creepy Child and throwing the dead bodies of all the soldiers he killed into a fire. And Gauron, being a messed up Ax CrazyPsycho for Hire, took an instant liking to Sousuke. He asked Sousuke to come with him, but Sousuke refused.
Kohei Kakihara and Chiko from The Daughter Of Twenty Faces. Kakihara is fascinated by her fighting spirit. His obsession to take away everything Twenty ever had may have something to do with this as well.
Orochimau to Sasuke in Naruto, where the villain isn't just interested in the hero's potential but wants his body too. It's later revealed that Orochimaru tried to do the same thing to Saske's elder brother, Itachi. But he apparently stopped after he received an asskicking by him.
Kyosuke to Kaoru in Zettai Karen Children. Incidentally, Kaoru also has a regular mentor, and the ultimate question of the plot is whether Kaoru will ultimately side with Minamoto or Kyosuke.
Bleach: Aizen's done this to a few characters. Orihime, for example. Once her powers came to Aizen's attention, he became very interested them. And when Masaki killed one of his hollow/shinigami experiments 20 years before the story began, Aizen became extremely interested in her.
For the dubious amount of villainy, Evangeline after defeating Negi says she won't kill him, because she found interest in him, but it's only when he ask her to teach him (after witnessing her power on a more serious level) that they become mentor and student.
In Fate Zero, Kirei Kotomine takes an interest in Kiritsugu Emiya, believing the two of them are Not So Different. He's wrong and is not happy when he realizes this.
In Fate/stay night, Kotomine meets Kiritsugu's adopted son, Shirou and takes a similar interest in him. To his delight, he finds that unlike Kiritsugu, Shirou is just as empty as himself.
In the Ultimate Spider-Man line, the second Spider-Man, Miles Morales, is approached by his uncle, the super thief Prowler, for training. Little does he know, the Prowler needs Spider-Man to deal with the extremely powerful Maximus Gargan—the Scorpion.
Ra's Al Ghul to Batman. He sees Bats as Not So Different, and was once interested in him being the successor of his organization, The Demon.
In the Green Lantern comics, Sinestro has taken an interest in Soranik Natu, the current Lantern from his home planet of Korugar. Where Sinestro was hated for being a Knight Templar tyrant (and the next Korugarian Lantern, Katma Tui, was hated by proxy), Korugar is coming to love Soranik. Both are viewing the peoples' growing devotion to her as practically asking her to be a dictator herself, which Sinestro views as her bringing order where he can't anymore while Soranik is greatly troubled by it. And it's no help at all that Sinestro is Soranik's biological father.
Teenage Mutant Ninja Turtles: Like Ra's Al Ghul to Batman, the IDW version of the Shredder has decreed that only Leonardo is fit to inherit leadership of the Foot Clan.
In Birds Of Prey Lady Shiva takes an interest in training Black Canary.
Luke Skywalker and Darth Vader have strong elements of this, minus the Foe Yay because, well, squick. The fixation leads to both Last-Second Chance and We Can Rule Together moments. Of course, from Vader's perspective, he is neither villainous nor beginning an interest.
Also the Emperor toward Luke, believing (rightly) that he is stronger than his father.
Treasure Planet does this, especially when it's becoming apparent Silver was Evil All Along. Subverted past the climax, however, when Silver slips into a somewhat benevolent role and loses his edge.
In the Fan SequelThe Silver Lining, Graham has a strange vision where Manannan claims his real plan had been to treat Alexander as an apprentice and surrogate child. Alexander's reaction to the revelation is a combination of squick/horror/disbelief.
After Gordon Freeman blows up the Citadel, it's made pretty clear that the Combine Advisors take a great interest in him and Alyx Vance, so much so that they begin keeping regular tabs on them and expend a large amount of troops to hunt them down. By Episode 2, they begin acting in person against the Resistance. Safe to say, it doesn't end well...
Robin and Slade from the Teen Titans cartoon. The similarity is emphasized whenever they fight each other, and especially when they fight together, as their fighting styles are nearly identical.
To a somewhat lesser extent, this is observable between Cyborg and Brother Blood as well.
Slade and Terra have a bit of this, too. Terra allows him to mentor her and...thingsgodownhill.
Ultimate Spider-Man is a Spider-Man franchise that justifies Peter's and Harry's friendship through this. Harry was nice one day and decided to give Peter a ride home instead of letting him walk through the rain. Harry's father, Norman, had heard of Peter's good grades and encouraged the friendship in the hopes that Peter would be a good influence.
Danny and Vlad from Danny Phantom. Vlad is fixated on Danny's mother, Maddie, and ultimately hopes to steal her away from Jack. Add the fact that Vlad and Danny are pretty much the only half-ghosts in existence, and Vlad sees Danny as the perfect Child Substitute. Naturally Danny doesn't see it this way.
Rex and Van Kleiss from Generator Rex. Although it seems that he is more interested in Rex's nanites than the boy himself.
Van Kleiss himself supplied that he would be happy if Rex was a vegetable as long as he was still breathing. Unlike some other examples, Rex is Genre Savvy enough to take advantage of this without entering such a relationship. In the episode "Alliance" Rex uses guile and half-truths to undermine Van Kleiss in various ways. Most notable of them is getting Circe to defect from the Pack. Circe was convinced that Van Kleiss wants to take Rex in like he did with her. So when Rex is forced into an arena with No-face for a no holds barred beatdown, Rex makes it clear to the onlooking Circe that Van Kleiss places no value on him other than his life.