In general, there is an allowance for pregnant and nursing women to break the fast.
There is a general evidence that comes from the same ayah that applies to those in very old age:
“…compensation can be made by feeding a needy person ˹for every day not fasted˺. But whoever volunteers to give more, it is better for them…” [Al-Baqarah, 2:184]
There is a report narrated by Abu Dawood from ibn ‘Abbas concerning the verse:
“And as for those who can fast with difficulty, (e.g. an old man), they have (a choice either to fast or) to feed a Miskeen (poor person) (for every day)” [Al-Baqarah, 2:184]
Ibn ‘Abbas said: “This was a concession granted to old men and women who are able to fast but with difficulty, they have the option of not fasting and feeding one poor person for each day instead.” [al-Nawawi classified its isnad as hasan]