Please run Sensor Test app... (Simple hardware tester / identifyer... there are many similar ones on Play Store)...
What do you see in Info for Accelerometer and Gyroscope?... Mine both show vendor = Bosch and Tests show good data. (... Tilt soccer game works

)...
Sensor hardware is often most affected by water damage... I lost Accelerometer, Gyroscope, Compass, and Magnetometer in my Xiaomi RN8T after dunkin' phone... Everything else still works fine...
Sadly I discovered these sensors are on main board in RN8T so can't repair... (Other sensors are on sub boards and are available for RN8T.)... I don't know where Accelerometer and Gyroscope (likely in same Bosch chip) are located in Mi Pad 4 variants...
Hopefully these sensors are detected... If not it doesn't necessarily mean physical damage... , could be vendor/firmware issue etc as has been mentioned... PW