cubes not rotating around the center

Good evening to all,

I’m trying to rotate several blue cubes (joined together) around the center, and I’m doing the same with a plane and another single cube (white).
The 5 cubes are related to a parent cube (Pent Cube) and the latter is connected to a rigidbody.

The problem comes when I want to rotate the blue cubes.
I click on the left capsule (to rotate the plane, the white cube and the 5 blue cubes).
The problem is that the blue cubes seem to be attracted by the left capsule which says to turn 90°, here is the code:

 void OnMouseDown()
    {
        plane.transform.RotateAround(Vector3.zero, Vector3.up, 90f);
        whiteCube.transform.RotateAround(Vector3.zero, Vector3.up, 90f);
        pentCube.transform.RotateAround(Vector3.zero, Vector3.up, 90f);

Normally the blue cubes should rotate 90f inside the plane (and not on the capsule), like the white cube does.

And here is a video to better understand:

Thank you all for your help.

A+

First thing to check is: grab those five cubes and rotate them with controls in the editor.

Until they rotate perfectly around this magical thing you call “the center,” nothing else matters.

Good morning,

my problem is that the blue cubes are pointing to the left capsule
(instead of rotating around the center of the plane).

Thanks for your help.