Hi there!
I think bread turns moldy less quickly when it is kept in a refrigerator than when it is kept at room temperature because bacteria eats foods like bread and causes mold, and less bacteria grow in colder temperatures. Since less types of bacteria thrive in colder temperatures, it takes longer for less bacteria to create mold.
Hope this helps!