The children, who crossed the border as unaccompanied minors, are being kept in shelters. Experts said the move raised troubling legal questions.