President Obama, on the heels of announcing his executive actions on immigration, teased Republicans about the immigration debate -- saying some of them think he's an "illegal immigrant."

The president made the wisecrack at a town hall meeting in Nashville on Tuesday. Discussing the immigration debate, he urged Republicans to work with him.

“Now, does that mean everybody is going to listen to me on the other side? Not necessarily. They’re pretty sure I’m an illegal immigrant,” he said. The crowd laughed, but just to be sure, Obama added: "That was a joke."

Still, Republicans aren't laughing as they debate how and when to launch a legislative counter-attack to his executive actions, which could give a deportation reprieve to up to 5 million illegal immigrants. If a spending bill outlined Tuesday night passes, it would tee up a battle over that plan early next year.

Obama on Tuesday stressed that he "wants to reflect the wisdom of the American people" and in doing so provide a chance to those living in the shadows with a legal system that is "more reliable, more certain, more fair."