Why does the refrigerator have a light but the freezer doesn't?

Frozen bulb would explode when heated.

Side by side fridges have light bulbs in freezer compartments and do not blow up. Same is true for bottom freezer units with a fridge on top.

Top freezer units usually don't have a lightbulb as it takes a lot longer to recover the cold temperature than bottom or side units.