Yes, it is illegal if you do that. and you will need a concurrent H1b to do that.