//UserStore & RoleStore
//UserManager, RoleManer and SignInManger
var roleStore = new RoleStore
var roleManager = new RoleManager
will add record to AspNetUserRoles but not the cookie. Later when we check the role using
The above code will return false because it checks the cookie. We need to re-signin the user to update the cookie
SignInManager.SignIn(user, false, false);
Identity information like roles and claims are stored in the cookie when user logs in.