Article I §8 of the Constitution, clause 18, the “Necessary & Proper Clause” authorizes Congress “to make all Laws which shall be necessary & proper for carrying into Execution the foregoing Powers, & all other Powers vested by this Constitution in the Govt of the United States”
It implicitly grants Congress the authority to enact a wide range of legislation to facilitate judicial power, including the authority to impeach & remove justices.