The boy, the son of a Danish-Somali woman, then arrived at Copenhagen airport the following day.
"He has been very sick and very malnutritioned," said Trier. "It's been a tough period for him, but he has gotten medical assistance. He's gaining weight."
His mother was an Islamic State supporter who was killed in an airstrike on March 17. He has been in a Syrian refugee camp ever since with authorities believing his Somali father is also dead.
The Danish news agency Ritzau said he is the first orphan to be repatriated back to Denmark from a Syrian camp.
Trier praised the Danish government for bringing the boy to Copenhagen.
"They did a very good job in securing this in a very difficult international environment," he said.
The grandparents and two aunts will now look after the boy in Denmark.
"It was a great day to see them reunited," Trier added. "He looks a lot like his grandfather."
-----------------------------------------------------------------------------------------------------