The main purpose of this legislation is to transfer the United States Marshals Service from the executive branch to the judicial branch of the government. This change aims to enhance the independence and accountability of the Marshals Service, which is responsible for various law enforcement duties, including the protection of federal officials and the execution of court orders. Key provisions of the legislation include the establishment of the United States Marshals Service as a bureau within the judicial branch.