Do I need this?
Only if you run your own mail server. Google Workspace, Microsoft 365, Zoho and the sending services (SendGrid, Mailgun, Amazon SES, Postmark) make the key for you and show you the record to publish, because they hold the private key and sign your mail with it. If you use one of those, follow its DKIM setup instead.
Why 2048-bit?
1024-bit keys are now considered weak, and some receivers treat them as a warning sign. 2048-bit is what Google, Microsoft and the RFCs recommend, and every receiver checks it. Longer keys don't fit comfortably in DNS.
What is the selector?
The selector is just a name that lets you have more than one key at once. Your server puts it in each signature (s=mail), and receivers look up the public key at mail._domainkey.yourdomain.com. When you rotate keys, publish the new one under a new selector, switch the server over, and remove the old record a few days later.
Is it safe to make keys on a website?
The keys here are made by your browser's built-in cryptography (WebCrypto), on your own computer. The page sends nothing anywhere and keeps nothing. If you would rather not trust any web page, openssl genrsa -out private.pem 2048 does the same job.