adding the posts controller and model