Is it failing when sharing directly to Youtube from iMovie - or - are you saving the movie to your camera roll and then trying to upload to Youtube from there?
A few things to try
1. Make sure you've installed all available updates for both iMovie and iOS
2. Verify that you have the proper username and password combo for YouTube and check whether you have 2 step verification turned on through Google
3. Make sure to try uploading while on a known good wi-fi connection
4. Restart your device and try the upload again
5. Lastly, a workaround, if you are able to export the movie to the camera roll, try copying it to your computer (via iCloud or syncing through iTunes) and use your computer to upload the movie to Youtube
Hope that helps