Not legit. Apple will never email you, unsolicited, and tell you to login to a web site with your AppleID.
While Apple does operate a forgot web site for AppleID password resets, it is highly unlikely that the link you received, regardless of what the email says as it’s name, is really going to any Apple site. The text shown in an email or document can be anything, while the underlying URL may be something else entirely.
You can simply change your AppleID password if your worried at -> Change your Apple ID password - Apple Support
(note that blue link text sends you to this apple support document -> https://support.apple.com/en-us/HT201355. The text shown above is placed in this message by the forum software since it is Apple’s forum and has access to the Apple support documents index name as well as its URL).
Also note Apple’s forgot site’s actual web address is https://iforgot.apple.com/password/verify/appleid. Note the iforgot and the https secure connection link