Because we have synonyms. Also, one take is because, semantically, there is a difference in degree. Something illegal would be expressly proscribed by a law; something unlawful would mean something is not expressly authorized.
Another take, however, says that illegal means against the law while unlawful is an act that is a contravention of rules in a given context. An example of this explanation would be catching the ball with your hands in a soccer/futbol game (assuming you are not tending goal)... It would be unlawful, but not illegal.
Finally, this answer over at StackExchange English provides another take.
According to Grammarphobia.com, in Black's Law Dictionary, illegal is "forbidden by law; unlawful." Unlawful is "not authorized by law; illegal." However, unlawful includes two other parts: "criminally punishable" and "involving moral turpitude."
However, earlier editions of Black's, such as the 1910 second edition say:
‘Unlawful’ and ‘illegal’ are frequently used as synonymous terms, but, in the proper sense of the word, ‘unlawful,’ as applied to promises, agreements, considerations, and the like, denotes that they are ineffectual in law because they involve acts which, although not illegal, i.e., positively forbidden, are disapproved of by the law, and are therefore not recognized as the ground of legal rights, either because they are immoral or because they are against public policy. It is on this ground that contracts in restraint of marriage or of trade are generally void.”
Finally, according to Oxford's English Dictionary, illegal comes from the French word illégal or the Latin illegalis whereas unlawful comes from Old English.