How to Hide JWT Authentication for WP-API Admin Menus

function plt_hide_jwt_authentication_for_wp_rest_api_menus() {
	//Hide the "Settings → JWT Authentication" menu.
	remove_submenu_page('options-general.php', 'jwt_authentication');
	//Hide the "Settings → ↳ Upgrade to PRO" menu.
	remove_submenu_page('options-general.php', 'https://jwtauth.pro?utm_source=wpadmin&utm_medium=submenu&utm_campaign=pro-submenu-link&utm_content=upgrade-to-pro');
}

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

Where do I put this code?