Gandalf says at the Council of Elrond that Tom has no power over the Ring, and
I believe Gandalf. Furthermore it is the most powerful entities who have
the most to fear from the Ring, which feeds on their power.
Instead, Tom is a simple spirit, in the best possible sense, just as the
hobbits are simple in the best possible sense. Tom's complete and utter
simplicity and lack of desire is the key to his immunity to the Ring, just as
the hobbits' relative simplicity and lack of desire is the key to their
resistance to the Ring. The hobbits are not quite as pure as Tom, and not
quite as immune -- but Tom embodies that which makes the hobbits resistant.
Tom functions as a threshold guardian, who gives the hobbits an adventure of
their own before the real quest begins, a sort of initiation, and awards them
with their weapons. Frodo, in particular, passes a test and finds his
courage inside the Barrow-mound, before he calls on Tom for a rescue. And
Tom teaches Frodo something Gandalf could not teach -- the art of detachment,
of simplicity, of resistance to the Ring. I don't think it is any
accident that Frodo winds up a noncombatant in the Scouring of the Shire, as
Tom was a noncombatant in the War of the
Ring.
“I dislike Allegory - the conscious and intentional allegory - yet any attempt to explain the purport of myth or fairytale must use allegorical language. (And, of course, the more 'life' a story has the more readily will it be susceptible of allegorical interpretations: while the better a deliberate allegory is made the more nearly will it be acceptable just as a story.)” (From Tolkien Letter # 131.)