To set up password protected network, or to configure additional network parameters, use the following overload:
WiFi.softAP(ssid, password, channel, hidden, max_connection)
The first parameter of this function is required, remaining four are optional.
taken from the page you referenced ....