The private prison company CoreCivic has sold two of the largest immigration detention facilities in California to the U.S.