it may be problem to change the path of WORK.
However, you might not need to.
You can use the same code but data will be written to "another path", if you use [pre] libname USER 'another path' ;[/pre] at the beginning of your SAS code.
Any dataset reference in SAS code with a single level name (that is, no libname) will be written to the USER libname once it is assigned.
Of course, as this is not the work library, you will have to manage its contents, and their deletion when appropriate.
This feature applies to data sets and data set views, not to catalogs.