How to Hide Two Factor Authentication Admin Menus

function plt_hide_two_factor_authentication_menus() {
	//Hide the "Two Factor Auth" menu.
	remove_menu_page('two-factor-auth-user');
	//Hide the "Settings → Two Factor Authentication" menu.
	remove_submenu_page('options-general.php', 'two-factor-auth');
}

add_action('admin_menu', 'plt_hide_two_factor_authentication_menus', 11);

Where do I put this code?