This strikes me as a very good question because from a modern perspective the heroes and villains in Homer's Iliad are sometimes difficult to identify. Also, the ancient definition of hero is different from the modern definition, and therefore many characters in the Iliad whom a modern person would never admire or want to emulate are, according to the ancient definition of the word, still technically heroes. For example, modern audiences don't seem to like Achilles very much since he cries to his mother and then withdraws from the fighting, which results in his friend's death, but from a literary perspective Achilles is still a hero.
Also, it is difficult to identify heroes and villains in the Iliad because so much strife exists within the various armies. To the modern reader of Iliad 1, Agamemnon certainly looks like a villain because his treatment of Chryses brings great hardship upon his own army.
From the Greek perspective, the Trojans are the villains. The Trojan Paris abducted a married Greek woman, Helen, and this action surely makes him look like a villain. Still, from the Greek perspective, Hector is also a "villain" since he is one of the Trojans. Homer's depiction of Hector, however, is so sensitively crafted that it is difficult for modern audiences to think of Hector as a villain and from a modern perspective Hector may be the closest person to a hero found in the poem.