Hmm... well, just changing the Z order might not work in this case
In Rising World, the Z order always depends on the Z order of the parent, or in other words, the parent automatically restricts the Z order of its childs (to avoid situations like having a button [child] being visible in front of the inventory, while the messagebox [parent] is shown behind the inventory)...
API elements are always attached to the HUD, and the HUD is always rendered behind the inventory/journal/crafting GUI.
However, our GUI already has an option to set a GUI element being always visible in front of other GUI elements (this setting is just not yet exposed to the API), internally this overrides the Z order. Maybe that would work in your case? You could set your confirmation window to be "always on top", so it will definitely be visible in front of the inventory or any other screen. Then we could add the .setAlwaysOnTop() method (and maybe also a .setAlwaysInBackground() method) with the next update 
Edit: Maybe a way to show and hide (.setVisible(false true) ) the inventory screen might work?
There will be some methods in the next update to show/hide the inventory as well as other screens (journal, chest content, map) 