I want to say I come from a city in the northern part of the country. Would the following be correct?
I come from X, which is a city in the north of the country.
It sounds unnatural.
The sentence, as Peter Shor says, is grammatically and even semantically correct, but not optimal. How you say it is a matter of style. I'd suggest this:
I come from Yilan, a small city in northeastern Taiwan. [Specific information is good]
You don't need the relative pronoun which or the copula is. It's usually better to use a short adjective phrase like northeastern Taiwan than a prepositional phrase like in the northeastern part of Taiwan because brevity is almost always a virtue.