AURORA, Colorado — The gunman who allegedly opened fire on a Batman movie screening in Colorado, killing 12 people, is being kept in solitary confiment for his own protection, police said Sunday.

James Holmes, a 24-year-old graduate student, was detained shortly after the shooting early Friday at a midnight screening of "The Dark Knight Rises" in Aurora, just outside Denver.

Asked if Holmes was being held in solitary, Aurora Police Department spokeswoman Jacki Kelley told AFP: "He's by himself," adding: "It's part of the protection process for him.

"Understandably this might be something that could upset other people. And it's part of the obligation to provide a safe environment for all the inmates in the jail," she said.

Holmes is being held in an Arapahoe County detention facility, she said.

Holmes is accused of bursting into a packed movie theater dressed in full body armor and gas mask, then throwing two tear gas canister-like devices into the crowd and opening fire on the film-goers as they scrambled to escape.