Changing rotation

Okay so I am making a game in which the player places furniture and decorations, inside an “invisible” grid. when rotating the furniture though, the furniture doesn’t rotate as I wish it would, because the objects are not cubes.
This is a Beach chair before rotation:


And this is the chair after I rotate it:

I want it so after I rotate it it would be like so:

Basically:

And not like that:

This is the function in which I create the objects:

 public void PlaceObject(float rotation)
    {
        Vector3 MousePosition = InputManager.GetMapPos();
        Vector3Int gridPos = grid.WorldToCell(MousePosition);
        Vector3 ObjectPlaceMent = new Vector3(grid.CellToWorld(gridPos).x + DesiredApparatus.Offset[0], DesiredApparatus.AObject.transform.position.y, grid.CellToWorld(gridPos).z + DesiredApparatus.Offset[1]);



        Quaternion Rotation = Quaternion.Euler(DesiredApparatus.AObject.transform.rotation.eulerAngles.x, rotation, DesiredApparatus.AObject.transform.rotation.eulerAngles.z);
        Debug.Log(Rotation);
        if (!DoesCollide(ObjectPlaceMent, DesiredApparatus))
            Instantiate(DesiredApparatus.AObject, ObjectPlaceMent, Rotation);
    }

I should mention the rotation float the function takes is for the rotation in the Y axis

You just need to change where the pivot of the root of the model is. Such as editing pivot in the mesh itself, or making it the child of an empty that positions the pivot at the right place.

How am I changing the pivot of an Object in unity?

Like I had just said, you can put the object under an empty game object which positions its pivot in the right place.

Otherwise you can’t change the pivot of meshes in Unity. That needs to be done in a 3d modelling program.