adding recursion on mkdir function