Hi, nicofs88,
Everything exported out of iMovie automatically is 16:9 aspect ratio that is the same aspect ratio as 1920 x 1080. You Tube supports that aspect ratio, so I don't know why You Tube is telling you that you have an unsupported aspect ratio. I have uploaded iMovie exports numerous times to You Tube with no problem.
To cover the bases you might want to try another export per the following: iMovie sets the project resolution as that of the very first video clip (not photo) that is inserted into a newly created project. So, create a new project. Insert a 1920 x 1080 clip into it to set the resolution. Then delete the clip and add your other clips. Click on the Settings button above the timeline to the right to check the resolution. If all O.K, export (share out) the project, to your desktop choosing the 1080 option in the share out settings box. From your desktop, open it in QuickTimePlayer and do a Window/Show Movie Inspector to check the resolution. If O.K, open You Tube and drag into You Tube's upload window.
If You Tube gives you the unsupported aspect ratio message again, then the problem is on You Tube's end.
-- Rich