Hi Giorgos,
Firstly, I would like to explain that the SharePoint Online is different from the SharePoint on-premise.
According to your description, this issue can be caused by differences between the features in SharePoint on-premise server and SharePoint Online server. The template cannot work if any differences between two site collections’ features.
Thanks,
Wilfred Ying