The Cosmological Principle is assumed to be correct but it's only an assumption. Observations verify it to ~experimental error at least within the observable Universe.
One seldom-discussed feature pertaining to the Cosmological Principle has to do with the consequences if there were an "edge". Ignore inflation for the moment because it complicates things, but I think the results would be the same with or without inflation. Also ignore the effect of dark energy, so this treatment applies most accurately to an earlier era.
Suppose the Universe is spherical with average density equal to the critical density (a function only of time) out to some radius r in cosmological coordinates (non-expanding coordinates, at least during the matter-dominated era), where r is large enough that it is outside the current observable Universe. Assume the density is zero at > r.
If we solve the "heavy dust" problem for a sphere we find that the first time derivative of the Hubble constant (H') is isotropic regardless of the observer's location and is proportional to the average density at the time. This is consistent with observation of course.
Now suppose that the Universe is not spherical. For example, assume it is ellipsoid with two minor axes = r and one major axis = nr (n > 1). The heavy dust solution now gives an anisotropic H' which depends on location. At the center, H'minor/H'major ~ n. (More explicitly, the minor axis deceleration is n times the major axis deceleration.)
This suggests that if the Universe is finite it must be spherical (although we could be anywhere in the sphere).
However if we extend r to infinity, the "heavy dust" solution gives us a weird solution: that the Universe cannot slow itself down because of the finite speed of gravitation. (Maybe Inflation fixes this problem.)