I have opened https://gitlab.winehq.org/wine/wine/-/merge_requests/6213 which I believe should fix the issue in a simpler way.
Note that it's not completely correct in any case, and there might be some unexpected behavior if applications rely on monitor display settings. We still allow different virtual desktop window sizes while the underlying virtual desktop size should always be the same as the monitor rectangles, which is normally (on Windows) the same across all the desktops of the interactive window station.