Add ModeT, Dir#mkdir and Dir#rmdir

Made some changes as per asterite's suggestions.