In Chapter 9: Emmeryn, Tharja appears as an enemy Dark Mage. She can be recruited by moving Chrom next to her and selecting the Talk option. After a brief conversation, she joins your units. To safely recruit her, try clearing the enemies around her as much as possible. Another option is to pair Chrom with a powerful flying unit and fly him over. You can move the flying unit he is paired with, swap to Chrom, talk to Tharja, and then even swap back to the flying unit if you would prefer.