originally, it was to warn the broadcaster that an ad break was coming and they would need to switch feeds from the programme to the adverts. i don't know if it still actually serves that purpose now everything is done digitally
It still serves its original purpose on live shows so as to allow some flexibility in the placing of ad breaks. Pre-recorded shows of course have fixed points for ads that can be set-up in advance and therefore generally do not require the cue dots, as they're called.