The doctor on board wears a single gold bar. In the Navy, this is an Ensign. As a Doctor the lowest rank he would have would be a Lieutenant, two silver bars.
Edit: Prior to this season Doc Rios was an enlisted surface force independent duty corpsman with the rank of Chief Petty Officer, they are highly trained medics who serve as the primary healthcare provider on smaller ships like frigates, destroyers and attack submarines and aren't actually doctors, they are just called "Doc" as a nickname and sign of respect for the vital role they play. After the pandemic the military is extremely short on doctors so Rios is attending medical school, someone joining the Medial Corps and starting medical school becomes a commissioned reserve officer with the rank of O-1, which would be an Ensign in the Navy, upon graduating medical school they are promoted to O-3, which would be a Lieutenant. So Rios' rank is correct for this situation, in fact by season five Rios is a Lieutenant indicating he finished medical school and is an actual doctor by that point.