Courses back-end setup

Readjusted code to new model setup. Commit includes setup of courses db, models and controller functions.