It's all about Creativity and Materials.
Since the question is specifically about firearms we are going to have to assume something to get him started. Lets maybe put him in a position to be exposed to gunpowder very early on. Once he knows what can be done, and he is creative enough, the rest becomes a process of iteration over time. We are also going to say that He is the keeper of all knowledge about firearms. That keeps it fairly simple.
The next assumption we have to make is that our immortal is very creative. Like Leonardo DaVinci creative. He needs an understanding of mechanisms that is far beyond common. DaVinci came up with tons of very creative ideas in one short lifetime and he was interested in everything. Granted, some of the ideas were not, strictly speaking, possible. But almost all of them had some seed of something that could work eventually. I always wonder what could have happenend if DaVinci had an unlimited budget.
Starting from those two assumptions we can proceed. First, Mr. Immortal learns about gunpowder and the advantages of chemical propellant. At this point he'll only have basic black powder to work with. Charcoal, Saltpetre, and Sulphur. All of these are going to vary in quality depending on tons of factors. Where was the Sulphur mined? Did he derive the saltpetre from Guano or by collecting the crystalized remans of evaporated urine? What wood was used to make the Charcoal? These factors influence the quality of the black powder. Our guy is going to have to spend a lot of time tinkering with the formula to get something consistently of high quality. Guano from a specific cave, Sulphur from Pompeii, and willow trees burned just right for the charcoal. Those are the kinds of things he'll have to figure out. It will take quite a while to come up with a specific formula.
Once he has a consistently performing black powder, then he can start looking at mechanisms and metallurgy for the weapons themselves. How fast will he figure out that Stone balls or Cast Iron are going to be very detrimental to the weapons themselves, leading to them failing quickly. He may well land on softer metals like lead to create cheap and consistent projectiles. He'l also likely come to the conclusion that Steel is the best thing for firearm barrels. Just like with the Gunpowder, he is going to have to tinker with composition until he finds the balance between weight, strength, and durability.
These two steps can overlap somewhat, but at a rough guess based on the breeze between my ears, will take about 100 years each. That puts him in a position of making very good, consistently firing cannons that won't fail randomly killing the gunners and that have controllable ranges.
His next round of development is going to be on 3 things: Rate Of Fire, Accuracy, and Portability. For rate of fire, he is going to try a number of things. Standardization of loads is one of the most obvious. A pre-measured packet of powder, standard wadding, standard ball will help. The real advancement will happen when he figures out Breech Loading. This gives him the concept of pre-loading something small and self contained, shoving it into the gun and firing from the pre-loaded thing. This concept pretty much applies to almost all modern firearms. You load one shell, fire it, eject the spent one, lock in the next, and fire. This is going to dramatically increase rate of fire.
He'll probably also work on Portability at about the same time. If I can have a big cannon, why not a small one a foot soldier can use? He has already got the basics of the metallurgy down. Muzzleloaders are easy and mechanically similar to cannon.
At the 3 hundred year mark, our man has Cannon, Field Artillery, and Musketeers.
Back to rate of fire. His next development is going to be around ways to make Open flame or fuses unnecessary. Precussion Caps and other primer based firing mechanisms that can fire even in bad weather. Mr. Immortal long ago learned the magic of standardization, so I don't thing it's too much of a stretch that he'll get to cartridge based weaponry in another 100 years.
The last part of this is going to be around accuracy. Rifling is one of those things that once you know about it you say "How easy is that?" Once you know that an arrow is more stable in flight if it spins, you are going to start wondering if that applies to high speed balls of lead. I imagine Rifling happens first in the big guns. Maybe shortly after (25 years or so) breech loading.
All put together, I'm guessing that Mr. Immortal gets to things like accurate Artillery, and hand carried rifles in 400 years. He might even get to Revolvers and Lever Action rifles in that time if He is dedicated in his pursuits and he gets to good cartridge based systems. To get much better arms like auto loaders is going to require him to push for much better machining, better propellant, and much better metallurgy. Unless he gets a lot of help, those probably won't happen in your timeframe.
EDIT: A Comment on a different answer reminded me of something. To go along with standardization, you need precision. For Cartridge fire weapons to be really reliable, you need to reproduce the parts exactly. He needs to work on that after he gets into breech loading. It's a really important step.