I'm not sure if you're confused about this, but many folks are.
China is also called PRC - People's Republic of China
Taiwan is also ROC - Republic of China
If one isn't aware of the history of these two countries, one can be easily confused. There was a civil war in China between the communists and the KMT during and after WWII. The KMT lost and fled the mainland to occupy Kinmen, Matsu, and the island of Taiwan. The tiny islands of Kinmen and Matsu are (to me) shockingly close to Mainland China. [Personally, I do not understand why China hasn't already 'absorbed' them back into the fold.
] The KMT government called itself the Republic of China and postured itself as a democracy.
Before the KMT government, its soldiers, and many civilians fled China, the ROC tag made sense. Today, after 66(?) years of not being in charge of the mainland, it makes little sense to me to still call it ROC. I'm an outsider, and I do not wish to offend any Taiwanese or Waisheng, so I will offer no more of my opinions on this topic.
I hope this has been helpful.