Obama was spotted with his wife, former first lady Michelle Obama, rockin’ it out on Saturday at a Beyoncé and Jay Z concert just outside the nation’s capital.
I find "rock it out" is defined in Urban dictionary:
A rock term. Do have several meanings, like:
-Same term as Rock On! Used to show appreciation for rock.
-Used for cheering at someone.
-Means that somebody does something completely to the limit.
It seems that the second one(Used for cheering at someone) is the closest to the context. Maybe, it just means they were out there to enjoy rock-and-roll music. I am not quite sure about it.