<pedantry> I've often heard that over the years, but after reading the books several times over the course of decades, and also reading of Tolkein's feelings on the devastation wrought by industrialization on the British landscape and people, and particularly of his horrific experiences in WWI, I have to wonder if maybe he doth protest too much in disavowing allegory in this particular work.
Perhaps it wasn't consciously intentional, but the parallels and influence of these things on the LOTR series are far too plainly clear for it to be "just a fantasy story". Perhaps it's a case of him not wishing to see the forest for the trees, or of him being somehow embarrassed by it in hindsight (feeling it to be too pretentious, maybe?). But JRRT saying that there's no correlation between the horrors of war he experienced and the aftermath of Man's domination of Nature in his own country is akin to, say, Picasso claiming later that his painting Guernica made no comment on fascism: you can deny it all you want, but the commentary you deny is writ large for the whole world to see. </pedantry>