updated models with relationships; added uniqueness index to users; added validations for users