Magento create Directory automatically if not exists with full directory hierarchy.

$baseDir = Mage::getConfig()->getBaseDir('media').DS.'registration'.DS.$this->getId();
Mage::getConfig()->createDirIfNotExists($baseDir);