Who pays depends on who provided the AC
If the landlord provided the air conditioning, they generally pay to repair it, because a landlord is usually responsible for maintaining the amenities they supply. If AC was never provided, the landlord typically has no duty to add it.
The answer turns on whether AC came with the rental. A central system or a unit provided at move-in is generally the landlord's to maintain and repair. If you brought your own window unit into a rental that never had AC, that is usually yours to handle.
A tenant might also be responsible if they damaged a provided unit through misuse. But when the landlord supplied the air conditioning, repair costs typically fall on them, not the tenant. If your landlord provided AC and is now trying to make you pay for repairs, a free review can help you understand what is fair.
This is general information about California tenant rights, not legal advice. Every situation is different.