I guess you really don’t comprehend the modifier “illegal”, do you. If they have a valid and unexpired visa they are not illegal. If they have valid documentation indicating their asylum status, they, too would also not be illegal.
I hope that helps you