(1) Someone could have tried to "hack" your account, and this email is to ask you, the owner of it, to confirm you are on that email address.
(2) However, someone could have registered an address and given your address as the verification address.
As MMDeveloper says, check the message comes from yahoo, in the way outlined in that comment.
The quandary you are in is knowing which of the two scenarios above apply. If (1) login to your account: if there's no problem logging in then I wouldn't click the link. If there is a problem, then you may need to click on it to "recover" from say an attempt at too many password retries by some would-be hack/crack attempt (2) do not click on the link: let it expire.