update creating folder logic