There are many ways to do a 301 redirect. For a Wordpress website, you can use Yoast SEOplugin, 301 redirect plugin or any other plugin. Besides this, you can also create 301 redirect in the .htaccess file.