I would guess that the units used in smoke alarms and microwaves generally have integrated drivers that only operate at a single frequency.
Yeah, you could more easily create a rhythm than a full melody. If you get a few devices, which beep at different frequencies each, you could do a lot more by having them beep in succession and in intervals.
Of course, this requires that they’re roughly in tune, which may not be the case at all. 🥴