A US soldier has pleaded guilty to murdering three detainees in Iraq last year, an Army spokeswoman said.