The issue is that the redirect and storage of the page to go to is saved on the server, and the hash from the anchor is never passed to the server since it is a client-side concept.
There is no easy solution to this. You could do something where the page is allowed to load without content and save the hash with javascript before forwarding it to the checkout page. If you know the page you want the anchor added on and you always want to use the same anchor, then you could hard code it.
This is probably a better topic for a premier support ticket if you need it, since the implementation could be tricky.