1. Create User migration with type:string
# rails generate devise User type:string
2. Create file im models folder
# admin_user.rb
3. Add inheritance from User model
class AdminUser < User
end
4. Now we can create admin users
# AdminUser.create(email:'test@test.com', password:'asdfasdf', password_confirmation: 'asdfasdf')
5. Check
u = Admin.user.last
u.type => 'AdminUser'