Hi Jeroen!
From your explanation it looks like you could make use of the default confirmation popup. In such cases there is often no need to pass around booleans and objects to custom yes/no pages.
If you are building a webapp using the delete logic in a microflow, this confirmation popup can be found under "microflow settings". You can edit the captions of the buttons as well. See the screenshot I attached.
.
Your microflow itself only needs to do the delete logic (and optionally related logic such as show a popup that the delete was succesfull or close/show other pages).
If, on the other hand, you use a nanoflow instead of a microflow, you can use the "show confirmation" activity, as mentioned in this thread.
Hope that helps!