I'm sure that's why kmessinger recommended the plugin route.
I haven't done what you want to do, but the codex makes some sence to me. It looks like you might start by adding the function to your theme and add your custom form id in this part
'form_id' => 'loginform-custom',
then use the given template tag in your login page template.