Studying the properties of the solvent around proteins, we propose a much more sophisticated model of solvation than temperature-independent pairwise interactions between monomers, as is used commonly in lattice representations. We applied our model of solvation to a 16-monomer chain constrained on a two-dimensional lattice. We compute a phase diagram function of the temperature and a solvent parameter which is related to the pH of the solution. It exhibits a native state in which the chain coalesces into a unique compact conformation as well as a denatured state. Under certain solvation conditions, both warm and cold denaturations occur between the native and the denatured states. A good agreement is found with the data obtained from calorimetric experiments, thereby validating the proposed model.