A bit confusing your questions as is, especially when you say you can add it to the article using php, but then that you can't figure out how to add it...
If I am getting you right, you want to place some php on the article's template file that will be generating a new custom instance of an installed module and will be displayed without having this module in the database.
Below is an example of doing this. In my example I am using the mod_custom (custom html module).
You can place this in the article's template, but make sure you have create a template override for your template.
$doc = JFactory::getDocument();
$module = JModuleHelper::getModule('mod_custom', 'Custom PHP Generated Instance'); // Use a such module title, so you won't load an existing module from the database.
$module->style = "System-html5";
$module->title = "PHP Generated Module";
$module->showtitle = "1";
$module->content = "This is the content of the PHP generated instance of mod_custom";
// Module Params
$moduleParams = new JRegistry($module->params);
$moduleParams->set('style', "System-html5");
// Debug the module
// echo '<pre>';
// var_dump($module);
// echo '<hr/>';
// var_dump($moduleParams);
// echo '</pre>';
//Render the module
$renderer = $doc->loadRenderer('module');
$moduleContent = $renderer->render($module, array('params'=> $moduleParams));
echo $moduleContent;
Play and experiment with the above code and adjust it to your specific needs and according to the params of your module.