Kepler's law is a universal law applicable to all two-body problems. Kepler's law is not only applicable to the solar system, it holds for both gravitational systems with central celestial bodies (such as planet-satellite systems) and binary star systems. For several celestial bodies moving around the same central celestial body, the ratio of the cubic orbit radius to the square of the period (R^3/T^2) is equal, which is (GM/4π^2), which is the mass of the central celestial body. This ratio is a constant that has nothing to do with the planets, and is only related to the mass of the central body, so if M is the same, the ratio is the same.
