Create helper method for creating directory