Arizona Senator John McCain, a Republican, has co-sponsored legislation introduced Friday which seeks to block President Donald Trump's ban on transgender troops.

In a statement, McCain declared his support for transgender people serving in the military.

“When less than one percent of Americans are volunteering to join the military, we should welcome all those who are willing and able to serve our country,” McCain said. “Any member of the military who meets the medical and readiness standards should be allowed to serve – including those who are transgender. The Senate Armed Services Committee will review the results of the DOD study on accession and will continue to work closely with our military leaders on any policy changes as we conduct oversight on this important issue.”

Trump first announced the policy change in July on Twitter. The White House last month issued guidance on implementing the ban. The guidance directs the military to bar transgender people from entering the military and to stop paying for the transition-related health care of active duty transgender troops, but stops short of banning transgender troops, leaving the decision of what the military should do about active-duty transgender troops to military leaders. The Pentagon on Friday said that transgender troops currently in the military can re-enlist as it studies the issue.

(Related: Transgender troops can re-enlist in military, for now.)

McCain's support for the bill is striking, given his opposition to lifting “Don't Tell, Don't Tell,” the now-ended policy that prohibited gay and bisexual troops from serving openly.

New York Senator Kirsten Gillibrand, a Democrat, introduced the legislation on Thursday after her amendment with identical goals to a must-pass military bill was blocked by Senate Majority Leader Mitch McConnell.

Senate Bill 1820 is also co-sponsored by Senators Jack Reed, a Democrat from Rhode Island, and Susan Collins, a Republican from Maine.

The bill, however, would not direct the Pentagon to accept transgender people into the armed forces. Instead, it relies on a military study on the issue announced June 30 by Defense Secretary James Mattis, setting a February 21 deadline for the study to reach Congress. It also does not mention the issue of transition-related health care, presumably an attempt to gain support among Senate Republicans.

(Related: House rejects Vicky Hartzler amendment that sought to block health care for transgender troops.)

In an interview Friday on WNYC's Brian Lehrer Show, Gillibrand thanked McCain for his support.

“What Sen. McCain did last night is agree that he will be on a stand-alone bill, which sends a huge message,” Gillibrand said. “I can’t tell you how meaningful it is to have the Chairman of the Armed Services Committee, a Republican, who clearly is devoted and loves the troops, to stand with me and Susan Collins to say this is wrong, you cannot be kicked out if you’re transgender, and that you cannot be discriminated against based on your gender-identity. It’s huge.”