Changing Doctypes module programatically

If I create a doctype in custom app and later want to change its module to an existing module of erpnext is that possible?

If there is no code associated with your custom doctype (inside your custom app), then you should be able to change the module.