The U.S. Senate on Thursday failed to advance a funding package amid disputes over immigration policy, increasing the risk of a partial government shutdown.