How to Hide WP Mail Logging Admin Menus

function plt_hide_wp_mail_logging_menus() {
	//Hide the "Tools → WP Mail Log" menu.
	remove_submenu_page('tools.php', 'wpml_plugin_log');
	//Hide the "Settings → Redux" menu.
	remove_submenu_page('options-general.php', 'redux-framework');
}

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

Where do I put this code?