Created models and setup relationships.