Tomohiro Kodama, 20, a sophomore at Seijo University, was arrested Tuesday night after allegedly kidnapping the girl, The Yomiuri Shimbun reported.
Authorities said Kodama allegedly approached the 12-year-old, who was waiting for her mother on her way home from school, threatened her with a fruit knife and ordered her to get into the bag. He then hailed a cab and asked to be dropped off at the Hiroshima train station.
The driver, Toshiyuki Hoshiyama, said he noticed something strange about the man and the bag, which was warm when he helped put it into the trunk of the car.
Then, he "clearly heard somebody in the bag shouting, 'Get me out!' when the taxi stopped at a traffic light," Hoshiyama told The Yomiuri Shimbun on Wednesday.
Hoshiyama said he asked Kodama about the bag, at which point Kodama said, "I'm getting off here," opened the door and tried to flee.
The driver quickly got out of the car and grabbed Kodama and yelled at passersby to call the police, saying there was a person trapped in the bag.
A man called police, then opened the bag and found the girl.
Police arrived and arrested Kodama, who may face charges of kidnapping a minor, the report said.
Notable deaths of 2014 [PHOTOS]
Ebola health workers killed in Guinea