The number in the bottom right corner of their avatar is the Mercenary’s level.
You need Mercenary XP to level up your Mercenary. Engage Targets with a Mercenary to earn XP for them. You can also retire unneeded Mercenaries in the “Upgrade” tab in your Mercenary Facility to get additional XP. Mercenary XP levels up a selected Mercenary to make them stronger.
The Level a Mercenary can reach depends on its Class. Class 6 allows a Mercenary to reach Level 40 if fully Promoted. A Mercenary’s Level is shown in the bottom-right corner of their avatar.