The advice is not to write your own login page, but to use the CredentialPicker control.
In your case, you are not hooking the picker into anything, and that is a valid scenario. Set the picker options up like this...
CredentialPickerOptions opts = new CredentialPickerOptions {
AuthenticationProtocol = AuthenticationProtocol.Basic,
Caption = "My App Login",
Message = "Log in here",
TargetName = "MyApp"
};
var res = await CredentialPicker.PickAsync(opts);
and then you can access the CredentialUserName
and CredentialPassword
values for your own logic.