This is not really an immigration question. If you are considering marriage to provide an immigration benefit to someone, that is another matter (and there is a "problem" with that).
If he entered the United States illegally even if you marry him he will not be able to stay here. You sound really young. I suggest you speak to someone (parent, priest, counselor, etc.) before you get married.