Tolkien's own words from Letter 154:
“Some reviewers have called the whole thing simple-minded, just a plain fight between Good and Evil, with all the good just good, and the bad just bad. Pardonable, perhaps (though at least Boromir has been overlooked) in people in a hurry, and with only a fragment to read, and, of course, without the earlier written but unpublished Elvish histories. But the Elves are not wholly good or in the right. Not so much because they had flirted with Sauron; as because with or without his assistance they were 'embalmers’.
They wanted to have their cake and eat it: to live in the mortal historical Middle-earth because they had become fond of it (and perhaps because they there had the advantages of a superior caste), and so tried to stop its change and history, stop its growth, keep it as a pleasaunce, even largely a desert, where they could be 'artists' - and they were overburdened with sadness and nostalgic regret.
In their way the Men of Gondor were similar: a withering people whose only 'hallows' were their tombs. But in any case this is a tale about a war, and if war is allowed (at least as a topic and a setting) it is not much good complaining that all the people on one side are against those on the other. Not that I have made even this issue quite so simple: there are Saruman, and Denethor, and Boromir; and there are treacheries and strife even among the Orcs.” -J.R.R. Tolkien, Letter 154