To be fair, maybe he DID know about the rule properly and was aware that he was fast running out of time to give the ball up....watch the replay again, he was on the last second of allowable time to hold the ball.
Better he do what he did than drop the ball from his hands and try to play it with his feet with the bahrain player so nearby. Or hold on to it and get an indirect free kick conceeded.
He did the right thing yes, cause yuh cyah complain that a man too near to yuh and blocking u from kicking the ball, and he had no other choice as all his players had run upfield, so no one to throw it too.