The alleged attacks took place on the Oscar Wilde, which is moored on the Rhine and houses Ukrainian refugees as well as paying guests.
Rachid is alleged to have followed the girl back to her room after they met at dinner on board the boat on March 6.
According to the indictment, he then forced his way through her door and raped her. The Ukrainian teenager tried to defend herself and was heard shouting “Stop! I don’t want that!”, the court document alleges.
Ten minutes after Rachid fled, Abdullahi allegedly burst into the girl’s room and raped her too, a court heard.
German prosecutors say though the attacks happened in quick succession, the two accused men are believed not to know each other and there is no evidence pointing to them working together.
Rachid and Abdullahi, like their victim, fled Ukraine after after the war began in February, travelling through Poland into Germany.
Both men hold Ukrainian citizenship and were originally refugees from Tunisia and Nigeria.
Rachid was studying to become a dentist and Abdullahi a computer engineer.
The men were not offered a chance to speak on the first day of their trial yesterday. If found guilty, both face a lengthy prison sentence and could be deported.
According to German news outlet Bild, the victim was not able to appear in court after testing positive for Covid.
Some 6.5million Ukrainians have fled into the EU since Putin launched his onslaught in February. Germany hosts around 900,000, mostly women, children and the elderly.
Refugees have fallen victim to a number of crimes including alleged sexual assaults.
German MP Andrea Lindholz said cops must “act immediately” and should do more to “specifically ensure the protection of Ukrainian women by checking accommodation”.
A police spokesperson said: “Politicians should now do everything to ensure that such terrible cases of rape as on the hotel boat in Düsseldorf do not accumulate.
“Harsh and swift punishment followed by deportation is the only language such perpetrators understand.”