What do you mean by "isolate" a program? Do you mean it runs completely independently of any other program? If so, then just running that program in batch mode will do what you want. A program run in batch mode has its own exclusive SAS session just for the duration of the program run.
I consider it best practice to globally assign shared SAS libraries (via SAS metadata) and share macro variables and macros (using AUTOCALL libraries). This reduces code inconsistencies and maintenance hugely. By setting up a common SAS environment shared by all SAS programs, the chance of interference between programs is minimal in my experience.