Commandant is a rank and title used by various organisations across the galaxy.
Starfleet Academy had used the title commandant to refer to high ranking officers in charge of the Academy. (TNG: "Coming of Age"; DS9: "Paradise Lost")
The Federation Marine Corps was run by the Commandant of the Federation Marine Corps. (Star Trek: Remington)
The Bajoran Militia was run by the Commandant of the Bajoran Militia. (The War of the Masters: "The Only Way to Go"))
The title of commandant was held by the commanding officers of shipyards in the early 25th century in both Federation Starfleet and Lyran Starfleet. (Star Trek: False Vacuum; Bait and Switch: "Shakedown Shenanigans")