Both Sodom and Gomorrah had been destroyed for their wickedness (Gen. 19). Whenever the prophets would call a people or nation by these names, they were metaphorically equating them with the former wicked people, and bringing to mind their eventual destruction. God saw them as spiritually the same as Sodom and Gomorrah.
Isaiah was quite upset with the children of Israel. The first verse of chapter 1 identifies the people to whom he was speaking.
"The vision of Isaiah the son of Amoz, which he saw concerning Judah and Jerusalem in the days of Uzziah, Jotham, Ahaz, and Hezekiah, kings of Judah." (KJV)
We can know, then, that the words of the prophet of this chapter concerned Judah and Jerusalem. Verse two:
"2 Hear, O heavens, and give ear, O earth: for the Lord hath spoken, I have nourished and brought up children, and they have rebelled against me."
Isaiah has not changed the subject yet. He has called both the kings/rulers and priests (their heavens), and the people of the land (their earth) to listen. In vs. 3, he charges them with less intelligence than the ox and the ass.
"The ox knoweth his owner, and the ass his master's crib: but Israel doth not know, my people doth not consider."
Isaiah lays it out very plainly again in vs. 4:
"Ah sinful nation, a people laden with iniquity, a seed of evildoers, children that are corrupters: they have forsaken the Lord, they have provoked the Holy One of Israel unto anger, they are gone away backward.
Vs. 7 - 8 speak of the warring between the northern 10 tribes and Judah itself, as well as the attacks from the surrounding nations during the period preceding the dispersion of northern Israel into Assyria. (See "Old Testament History Assyrian Dominance" here.)
And, then vs. 9 clearly states the comparison:
" Except the Lord of hosts had left unto us a very small remnant, we should have been as Sodom, and we should have been like unto Gomorrah."
With the comparison defined, then each time Sodom and Gomorrah are used hereafter, they would know Isaiah was prophesying Judah's complete destruction as God had wiped clean the plain of Sodom and Gomorrah from existence. Emphatically, vs. 10 cries out....LISTEN TO ME!.. you wicked people.
Barnes' Notes on vs. 10:
"Hear the word of the Lord - The message of God. Having stated the calamities under which the nation was groaning, the prophet proceeds to address the rulers, and to state the cause of all these woes.
Ye rulers of Sodom - The incidental mention Sodom in the previous verse gives occasion for this beautiful transition, and abrupt and spirited address. Their character and destiny were almost like those of Sodom, and the prophet therefore openly addresses the rulers as being called to preside over a people like those in Sodom. There could have been no more severe or cutting reproof of their wickedness than to address them as resembling the people whom God overthrew for their enormous crimes. " (Source: BibleHub)
The sacrifices of vs. 11 were not those of Sodom and Gomorrah, but the worthless and vain sacrifices of Judah (vs. 12-14). They had become ritualistic motions, empty of true worship, without heart and understanding, without spirit and truth (John 4:23-24).
These comparisons are used again in Jer. 23:14,
"I have seen also in the prophets of Jerusalem an horrible thing: they commit adultery, and walk in lies: they strengthen also the hands of evildoers, that none doth return from his wickedness; they are all of them unto me as Sodom, and the inhabitants thereof as Gomorrah."
Ezekiel used the spiritual reference of Sodom against Samaria / Israel, the "sister" of Jerusalem. Ezek. 16:48,
"48 As I live, saith the Lord God, Sodom thy sister hath not done, she nor her daughters, as thou hast done, thou and thy daughters.
49 Behold, this was the iniquity of thy sister Sodom, pride, fulness of bread, and abundance of idleness was in her and in her daughters, neither did she strengthen the hand of the poor and needy."
And, we see it again in Rev. 11:8,
"And their dead bodies shall lie in the street of the great city, which spiritually is called Sodom and Egypt, where also our Lord was crucified."
The "great city" where Christ was crucified was Jerusalem, and was again called "Sodom" as well as "Egypt", two people whom God had destroyed for their wickedness.
They were metaphors and being called by the name of a destroyed people was to tell Jerusalem / Judah of their danger and pending destruction.
(All scripture is from the KJV. All bold emphasis is mine.)