Can we clarify what 'Z order' we talk about ? Z order based on IID or Z order based on Y(x) ?
Let me try to explain.
Based on IID. When you copy or clone in the layout. The last one created shows above the others. The same for newly created instances during runtime. The last created one show above the others. It has a higher IID (when picking all) and a higher Zindex.
(problem could be solved with a fake IID index in a familie variable)
Based on Y(x). Those objects with a higher Y show above those that have a lower Y. Usaly used for dimetric games.
(problem could be solved with plugins)