Why do errors exist in peer reviewed publications? I found a mistake (not a misprint) in an article which has been published in a very good math journal. According the available data, the article was in peer-review process for more than 8 months. But I do not know why the referee(s) did not notice that. What are reasons for this kind of articles?
People make mistakes.
Manuscript authors, reviewers, and editors are people, and people are not perfect. Even if every person involved in the publication of a manuscript catches 99% of all errors, it's still possible that some errors will go unnoticed. This likelihood of course goes up  when authors/reviewers are careless, but it can never be eliminated entirely even with very meticulous review.