Yep, Barack Obama said that:
That’s the good thing as a president. I can do whatever I want.
The context was relatively benign, breaking the rules for Monticello visitors, or something like that. (It wasn’t like he was claiming the right to unilaterally alter the law or anything outrageous like that.) What’s troubling is the mentality that leads him to say things like that, out loud, in public.
This is America, and Obama is a president, not a king. You’re not supposed to talk like that. The president serves the people, he is not above the people. And he does not seem to understand that at all.