Add a custom variable to query page object

I updated my question with a partial answer to this problem. By adding an underscore ‘_’ before the name of the meta field it allows you to add meta data without it creating an editable custom field on the page edit screen.

update_post_meta( get_queried_object()->ID, '_term_id', $meta_term_id);