Improve db

#8 @gsathya @ben-jones 
I changed directory structure and split server.py into models and views.
shouldn't it through an error if the user did something like that?