If you have 10 villagers (regardless of if one is moving) you can not hold a villager from someone else's void. The same as how you can't ask anyone to move in, not until you are down to 9 villagers. If they don't have anywhere to go immediately they dissolve, in theory. I'm sure there's gonna be someone with an exception, but 95+% of the time you won't get a villager that way if your town has its max villagers.
If you only have 9 then yes, you will pick up villagers from any visitor's void or from streetpass. HOWEVER, there is a grace period between when your boxed villager leaves and when anyone new will move in of ONE DAY. So the very first day after your TENTH villager moves out no one will be plotted, even if someone is somehow stuck to your void they won't house plot til the second day after the villager is gone, giving you that day to ask someone to move in from another town so you aren't stuck with someone random if you don't want to be.
I used to make a new character every time someone moved out to make sure I didn't have any random move ins and NEVER ONCE did I have anyone moving in the next day, eventually I stopped because its such a waste of time and in almost 2 years playing and multiple towns and resets and lots and lots of villager movement this has always been my experience.
Hope that answers your question.