As you mentioned you can successfully use the scan functionality on your local workstation and Dynamics GP 2018 R2, I'm curious if you can then also take one of the servers in the Citrix environment, and instead of going through a Citrix session, use just Remote Desktop if you cannot physically logon to the server, and then verify in Dynamics GP 2018 R2 on that server whether or not the scan button in Document Attach works like it does on your workstation or not?
I say this because, even though Citrix support can't identify any blocking, we see enough issues show when using Citrix on an environment with Dynamics GP, that we don't normally see nor can re-create, so that we treat Citrix like a third-party product, meaning we try to remove it from the equation completely, so we can determine if it truly is a Dynamics GP issue.
If we can remote onto one of the servers in the Citrix environment without going through Citrix, and the scan functionality works, then we'd have shown that the issue seems to lie with Citrix, especially if we can then logon to that same server but this time going through a Citrix session, and have the scan functionality stop working.
As you can successfully scan on your workstation, it would seem you're using the TWAIN drivers so that doesn't seem to be an issue, so I would test removing Citrix from the equation on one of the servers and see if the issue still shows or not.
Thanks