IME, mature Peafowl usually take longer than a couple/few weeks to imprint on a new home to the point they will stick around when they are let out to free range. They need plenty of time to forget about their previous home so they don't wander off trying to find where they used to live. Plus if you've been handling him to medicate him then as soon as you let him out he may take off to get away from being handled again. With it being the tail end of breeding season (which is most likely why he was fighting with the "other Peacock" in the mirror at the vet's office), he may wander off looking for a mate or other Peafowl. If possible I'd find a healthy Peahen for him ASAP... and then keep them both penned (separated from your other poultry) for at least a couple months so they have time to bond with each other as well as acclimate to where their new home/shelter is, and where their new source of food & water is.
This is JMO and what I would do, others may have different advice.