public function rename($rdn, $newParentDn = null, $deleteOldRdn = true)
    {
        if ($newParentDn instanceof Model) {
            $newParentDn = $newParentDn->getDn();
        }

        $moved = $this->query->getConnection()->rename($this->getDn(), $rdn, $newParentDn, $deleteOldRdn);

        if ($moved) {
            // If the model was successfully moved, we'll set its
            // new DN so we can sync it's attributes properly.
            $this->setDn("{$rdn},{$newParentDn}");

            $this->syncRaw();

            return true;
        }

        return false;
    }