is there any macro that can move object next to the previous object just like in the attached GIF ?
Yes, use it everyday. It's called ButtShapes.
can you please share with me.