Commander

Commander is a rank of naval officer. It may also be used as a general term for a leader. 
Commander as a naval rank.
Commander is a rank used in many navies and some air forces. It is rarely used as a rank in armies, except in special forces for a team leader. 
The title (originally "Master and Commander") originated in the 18th century Royal Navy for naval officers who commanded ships of war too large to be commanded by a Lieutenant but too small to warrant the assignment of a Post-captain. 
In practice, these were usually unrated sloops-of-war of no more than 20 guns. The Royal Navy shortened "Master and Commander" to "Commander" in 1794; however, the term "Master and Commander" remained in common use for many years. A corresponding rank in some navies is frigate captain. In the 20th and 21st centuries, the rank has been assigned the NATO rank code of OF-4.
Royal Navy.
A Commander in the Royal Navy is above the rank of Lieutenant-Commander, below the rank of Captain. It is equivalent in rank to a Lieutenant Colonel in the British Army and Wing Commander in the Royal Air Force. A Commander may command a frigate, destroyer, submarine, aviation squadron or shore installation, or may serve on a staff.