President Obama gave an interview before the 2016 election where he was asked about illegal aliens. He responded that they will not be coming for them to deport them. He also urged Latinos to get out and vote. He did not encourage illegal aliens to vote.
However, right-wing media outlets took it out of context and blamed Obama for urging undocumented illegal aliens to take part in the 2016 election and do their best to vote. This is simply not true and anyone with half a brain could see that Obama was encouraging legal Latinos to get their vote heard because of the divisive rhetoric from the Trump campaign