Yes -- if you use that specific phrasing, "your character would not do that", you are denying their character's agency. The player is an authority over what their character wants to do; your authority is over what the character can do. Rather than tell the player that their character doesn't want to do something, instead express it as their character's inability to do something.
Druid: I put on the chain shirt.
DM: You reach down and try to put on the chain shirt, but something is wrong. You can't figure out how to wear this object. You're sure that your arms are supposed to go somewhere, and you can guess there's a part that goes over your head, and theoretically you know how it all fits together -- but as soon as you try to actually do it, your mind goes blank and you have no idea how to even start putting it on.
The above is still sort of inadequate, because a motivated player can find a way around it -- for example by asking the wizard to polymorph the druid's leather armor into plate mail, or by asking the fighter to knock the druid out and dress them in plate armor while they're unconscious.
The problem we're having here is arguably caused by a failing of the 5e Player's Handbook, which states that the druid will not wear metal armor, but doesn't otherwise describe the consequences. To fix the problem, you need to do some worldbuilding. What happens to a druid that wears metal armor, perhaps against their willWhat happens to a druid that wears metal armor, perhaps against their will? You need to fill those details in. Ultimately, you want to tell the druid something like: "well, technically you can choose to wear the metal armor, but it's a really bad idea because you'll face the following consequences..." Make up some consequences so horrible that no sane druid would ever wear the armor.
Druid: I put on the chain shirt.
DM: You think about putting on the chain shirt and you can sense clearly that it would lead to disaster. If you turn your back on Nature in this way, then Nature will turn its back on you, and the ways of the animals will be forever closed to you. Are you sure you want to do this?
or:
Druid: I put on the chain shirt.
DM: You think about putting on the chain shirt and for some reason it fills you with dread. You get images of shackles, chains, manacles, closing about your body, cutting off your freedom, cutting off your connection to the world -- it's so simple an act, but it's the most horrifying thing you've ever comtemplated. If you're sure you want to do this, I need you to make a Charisma save -- and I'll need more saves, regularly, not to panic once the metal is around your body.
or:
Druid: I put on the chain shirt.
DM: The 5e rules don't say anything about what happens if a druid wears prohibited armor -- they just say you can't do it -- so we're going with the 3.5e version instead. If you wear prohibited armor, you lose all your druid class abilities, including access to druid spells, while wearing the armor and for 24 hours thereafter. Do you still want to do this?
Now that you've phrased it like this, it's no longer denying the character's agency -- now you're technically offering them a choice, but a choice that is heavily weighted so that it's functionally identical to the Player's Handbook rule.