Sometimes I need to sign in to my WI-Fi and other times I don't. How is it SUPPOSED to work? Is there a document somewhere that explains what I can expect with regards to logging on to wifi networks ?  IE: When will I have to log on, if I enter a password, will the phone remember it the next time I log on to that specific wifi network ? Things like that.
You'll normally be prompted to enter passwords on encrypted Wi-Fi networks (WPA/WPA2, WEP etc) or even WPS Wi-Fi networks.

Encrypted Wi-Fi networks usually have a padlock icon.

For open networks, you can connect without need of a password.  (These kind of networks don't have the padlock icon)

Once you connect to either type of wi-fi , these settings for that access point are saved automatically, such that you don't needlessly enter again a password upon reconnection (in the case of encrypted ones). Android can remember such access points.

There are other kinds of wi-fi networks, that require additional login steps on an ISP webpage (Captive portals), in this case the initial connection is automatic, then you'll need to enter login details (e.g email/id and access password)