The verse literally refers to idols, which indeed are "not gods." In isolation the verse does not teach that there are no other gods in the spiritual realm. However in context it seems to represent a transitional movement in Israelite religion. In the earlier "Yahweh-only" movement, the prophets emphasized that "other gods" must not be worshiped by Israel, even though they might exist. But here, the chapter shows the influence of the prophet Isaiah on the king of Judah (19:2), and the teaching goes beyond a teaching not to worship other gods to affirm a true monotheism. A few lines later, as King Hezekiah implores God to save his nation from the Assyrian enemy, he says:
"So now, O Lord our God, save us, I beseech thee, from his hand, that
all the kingdoms of the earth may know that thou, O Lord, art God
alone.” (Is. 19:19)
Here, God is the only God, universally. But other passages show what is probably an earlier attitude in which Israel's deity is more powerful. For example Psalm 86:8 states: "There is none like you among the gods, O Lord..."
Deuteronomy 32 says:
Remember the days of old,
consider the years of many generations; ask your father, and he will show you;
your elders, and they will tell you. When the Most High gave to the nations their inheritance,
when he separated the sons of men, he fixed the bounds of the peoples
according to the number of the sons of God. For the Lord’s portion is his people,
Jacob his allotted heritage.
This passage invokes an earlier time when Yahweh is given a "portion" of people: Jacob/Israel. However, other people belong to other deities. It even appears that the Most High (ʿelyôn) here is the Supreme deity while Yahweh is one of the ben-elohim - the "sons of [the]God/s" who each received a portion of the human population.
Psalms 82 also speaks of the God of Israel [elohim] was one among many gods, rather than the only God.
God has taken his place in the divine council;
in the midst of the gods he holds judgment...
I say, “You are gods,
sons of the Most High, all of you;
nevertheless, you shall die like men,
and fall like any prince.”
Here, the old gods are dying out, so to speak, and Israel's God has become dominant. The passage from Deut. 32 refers to an earlier time, when it was
elyon who was the highest deity, and yahweh received an apportionment from him. (Understand that this is not my understanding of what actually happened, only of how I see the Israelite religion progressing from a belief that Elyon was the highest deity to a belief that Yaweh was supreme but not the only God, etc.)
The general attitude prior to Isaiah's ministry seems to have been that while other nations have their deities, Israel must worship only the God of Israel. The commandment was "I am the Lord your God who brought you out of Egypt... you shall have no other gods before Me," (Ex. 20) not "I am the universal God for all nations, and no other gods exist." But in 1 Kings 19 we see that God is indeed to be recognized as the sole deity for all people.
So it seems that Isaiah's ministry in 2 Kings 19 represents a transitional phase from henotheism (Yahweh is Israel's only God) to monotheism (Yahweh is THE only God).