Brazil's election laws, don't allow ads that attack candidates immediately before an election. When a court in Brazil ordered them to take down the video from their YouTube site, they refused, citing that they were a platform and not responsible for content posted on their site by third parties.
Google have previously stated that "voters have a right to use the internet to freely express their opinions about candidates for political office, as a form of full exercise of democracy, especially during electoral campaigns."
That maybe so, but election laws requiring broadcasters to maintain impartiality during election campaigns are common throughout the world, and Google may have to adapt to that. It's certainly not unheard of for it to respond to other take down requests, and it did famously cooperate with the Chinese authorities to censor it's search service. A policy which attracted much derision at the time and was later rescinded. Political videos may, however, be a different matter as they go to the core of democracy and freedom of speech. Censoring them could be considered bias, and like Twitter, it could be argued that a YouTube video is just one persons opinion with no authority other than their argument, and should be treated as individual comment rather than published editorial or broadcasting.
However, in this case, Judge Flavio Peren disagreed and ordered Fabio José Silva Coelho's arrest. I understand Google is appealing the decision. In any case, the charge is considered minor and he is expected to released later today. Just this month another Google executive, Edmundo Luiz Pinto Balthazar, was arrested for refusing to remove a video mocking a mayoral candidate, but was released following a ruling by another judge a few days later.