To expand on Peter Winnington's answer and fill in the details from the article and journal, which is now freely available on JSTOR (you do need to create an account though). Winnington is the author and publisher of the journal.
Winnington in his article makes a very valid point that the location exists only in Peake's mind - there are many logical inconsistencies in the story, such as Gormenghast being isolated almost entirely from the world, but still having things like massive libraries (e.g. Lord Groan's), firearms, a globe ("Cane Slypate thursday"), Dr Prunesquallor's sister Irma reads lady's journals for the latest fashions etc., and not least Bellgrove barking
"Name an Isthmus"
when awakened from his dozing in front of his class; an isthmus being something that Gormenghast doesn't have. In addition the school boasts a chemistry teacher - such an esoteric field being difficult to imagine being created in isolation from the rest of the world.
Having seen these exceptions Winnington mentions Countess Groan stating
"There is nowhere else"
As well, a general sense of isolation and insularity is prevalent in the books. The isolation of Gormenghast is a major feature of the story with no mention of any other location outside of the castles and vast forests that surround it.
Winnington then goes on to speculate that whether intentional or not, the country where Peake grew up, China, was, until around the time of Peake's birth, isolated much as Gormenghast is, and contains climes similar to those of Gormenghast. To quote a significant paragraph of the article:
Whether by accident or design, it happens that Gormenghast is geographically situated in a manner that recalls China: “the wastelands” to the north correspond to the Gobi desert and Mongolia, there is a shallow sea to the east and more sea to the south, while to the west the “knuckles of endless rock” correspond to the Himalayas and the Sinkiang. Tientsin, where Peake spent most of the first ten years of his life is close enough to the Gobi desert to suffer from sandstorms; significantly, the Gulf of Chihli, which lies but forty miles to the east of Tientsin, is to all intents and purposes “tideless”, being an enclosed coastal sea, little more than a large bay of the Yellow Sea. Its coast is flat and swampy with “grey salt marshes” created by the alluvial deposits of the major rivers flowing into it. So if I were pushed to place Gormenghast on the map of the world, I should point to Tientsin, or of course to Peking, which lies less than 80 miles to the north-west of Tientsin.
Thus China may be a (perhaps subconscious) influence on the story and is one likely location for Gormenghast.