As is well known, D&D characters who attain high levels gain the ability to build strongholds and accumulate followers. The precise rules for this vary by edition - some retroclones* being especially well-known for expanding on this playstyle - and by class, but it's a pretty universal element.
|Art by Ted Nasmith|
"After the fall of Sauron, Gimli brought south a part of the Dwarf-folk of Erebor and he became Lord of the Glittering Caves. . . . Legolas his friend also brought south Elves out of Greenwood, and they dwelt in Ithilien, and it became once again the fairest country in all the westlands." - The Lord of the Rings, Appendix A
Now, despite my clickbaity headline, I doubt this passage had much to do with what we call the "Domain Game" of early D&D. In fact, I would tend to think the concept as driven more by gameplay needs than anything in fantasy fiction at the time, though I welcome further examples. Still, it's a remarkable correspondence in concept, and one that I certainly wouldn't mind exploring at the table someday.