As a learner it feels like Japanese is full of this kind of formalized, preemptory apologizing in all kinds of situations. You go to the supermarket and ask if they sell stamps (the answer is no) and they say the formal apology "申し訳ありません" (literally: I have no excuse).
There's also ごめん下さい "gomen kudasai" (literally "please forgive me") which is used as a greeting when visiting someone's house unexpectedly. And どうもすみません "domo sumimasen" (literally "thanks excuse me/I'm sorry") when accepting someone's offer to help with something.
None of these necessarily imply the speaker has actually done something wrong or wouldn't do the same again.
There's also ごめん下さい "gomen kudasai" (literally "please forgive me") which is used as a greeting when visiting someone's house unexpectedly. And どうもすみません "domo sumimasen" (literally "thanks excuse me/I'm sorry") when accepting someone's offer to help with something.
None of these necessarily imply the speaker has actually done something wrong or wouldn't do the same again.