I've never understood why Windows defaults to "public" when the vast majority of times people are trying to share on their LAN only. I don't think I changed the default.
Security. By default, inbound connections should always be blocked, no matter what, because it can't know for sure whether you're on a private LAN or if the outside world has access. It would make more sense though if they prompted you to change it if you explicitly were turning on shares, instead of requiring you to dig to change it. At least Windows 7 prompted you the first time you connected to a network, even though it might later change it without informing you. (10 and 11 seem less reliable about prompting.)
The easiest way to change it is to just open File Explorer and click on Network to browse, and if it's Public you'll get a prompt bar at the top about turning on sharing. On rare occasions, it can be set to Private but still have sharing disabled, and you have to go into the sharing settings to change it then.
As to credentials, yes, as long as you have a username and password configured on the computer, and didn't take the extra steps necessary to share using guest credentials, it will just prompt you. (Though if you use the same credentials on both, it won't prompt. And if you use the same username on both but different passwords, it won't work without manually storing the right credentials in Credential Manager.)