Model for user registration
Added test and fixed registation model