renegade
n.someone who leaves their group, country, or set of beliefs to join the other side. You use this for a person who refuses to follow the rules and acts independently.
n.a person who deserts and betrays an organisation, country, or set of principles. Often carries a connotation of rebellious independence or lawlessness.
“The renegade soldier joined the enemy forces.”
“He was considered a renegade by his former colleagues after he leaked the company's secrets to the press.”
“The film depicts a renegade detective who ignores bureaucratic procedures to pursue a personal vendetta against the city's most powerful criminal syndicate.”
Often used attributively as a modifier before another noun (e.g., 'renegade priest').
From Spanish renegado, from Medieval Latin renegātus, perfect participle of renegō (“I deny”). See also renege.
Etymology adapted from Wiktionary, available under CC BY-SA 4.0.