I work with students, so I sometimes hear the depressed, "I'm so stupid." Or, in PE, "I'll never be able to do that." No one is ever happy at such times, but depressed, thankfully, usually passing when assured they can learn, they can improve. Religion is an area of knowledge, a practice geared toward improvement. Take away any area of knowledge or practice--and that includes religion--may result in depression.
Lack of religion is not the only lack that can cause societal depression, and everyone practicing a religion is not the cure-all, either. Depression often stems from feelings that something is lacking--and that "something" is not always religion. In some cases it may very well be, and let's not overlook those some.