The DCREATE function can be used to create directories independently of the OS.
Thanks to Art Carpenter for this tip. Read more details in this paper from WUSS 2017: Building Intelligent Macros Using Metadata Functions with the SAS Macro Language.
Nearly 200 sessions are now available on demand with the SAS Innovate Digital Pass.