Highly theoretically, it has to do with will; as Galadriel says to Frodo:
'I would ask one thing before we go,' said Frodo, 'a thing which I often meant to ask Gandalf in Rivendell. I am permitted to wear the One Ring: why cannot I see all the others and know the thoughts of those that wear them?'
'You have not tried,' [Galadriel] said. 'Only thrice have you set the Ring upon your finger since you knew what you possessed. Do not try! It would destroy you. Did not Gandalf tell you that the rings give power according to the measure of each possessor? Before you could use that power you would need to become far stronger, and to train your will to the domination of others.
Fellowship of the Ring Book II Chapter 7: "The Mirror of Galadriel"
Even ignoring the fact that Frodo can still speak whilst invisible, the Ring appears to be controlled not as much by vocal commands but by the desire of the wielder.
Tolkien discusses the possibility of Frodo using the Ring in Letter 246, and it basically comes down to strength of will:
Frodo had become a considerable person, but of a special kind: in spiritual enlargement rather than in increase of physical or mental power; his will was much stronger than it had been, but so far it had been exercised in resisting not using the Ring and with the object of destroying it. He needed time, much time, before he could control the Ring or (which in such a case is the same) before it could control him; before his will and arrogance could grow to a stature in which he could dominate other major hostile wills.
The Letters of J.R.R. Tolkien 246: To Mrs. Eileen Elgar (draft). September 1963
In this particular case, though I don't believe Frodo is being entirely truthful; discussing the power of the Ring, Tolkien writes:
[T]he Ruling Ring [...] contained the powers of all the others, and controlled them, so that its wearer could see the thoughts of all those that used the lesser rings, could govern all that they did, and in the end could utterly enslave them.
The Letters of J.R.R. Tolkien 131: To Milton Waldman. 1951
Which suggests that the One can control the bearer of the Seven, the Nine, and the Three, but cannot inherently dominate the minds of individuals not wearing Great Rings. In the specific case mentioned in the question, it seems more likely that Frodo is simply trying to intimidate Gollum, rather than making an actionable threat.