Maybe take a look at setting them in your .Renviron file instead?
I'm suggesting it because that file was in my Documents folder (which I'm hoping you can edit), and I had it WRONG in mine.
The environment variable defined there incorrectly was the only one R would pull, and I only solved my problems after I got that incorrect variable out of the way.
Maybe try https://forum.posit.co/t/how-to-set-a-variable-in-renviron/5029?