createDir is OS compatible