What the international law cares about is "sovereign states" or "sovereign subjects of international law" not countries which is a much more informal term. Sovereign states technically don't even need a territory - 122 states have official diplomatic relations with the Sovereign Military Order of Malta (not to be confused with the Republic of Malta) which has had no territory since 1799.
Eh, the British "countries" are countries in name only. They don't really fit any of the usual things people would think of as constituting a country.
In reality, they're constituted like less than the state of a federation like the US, Germany, or Australia. A state has a constitutional right to its governance, and cedes some power to the federal government. The devolved governments of Scotland, Wales, and Northern Ireland are rights granted by Westminster, and could be taken away at will. Nothing Biden, or Trump, or Mike Johnson wanted could ever take away Maine's right to its own governance like that.