Hi Mohit,
Thank you for posting your issue here.
As I can see in the attached screenshot the public link is already created and you want to update it. But the existing Public or Private link cannot be changed to Password-protected link.
To create password protected link you have to create a New link. To create a new link click on the "Link" dorpdown and choose "New Link" option. Once you open New Link you should be able to see "Anyone with password" option the Link Access dropdown.
I hope it helps.
Let us know if you have more queries related to this.
Regards,
Abhishek Das (Adobe XD Team)