The Prophet ﷺ omitted the iʿtikaf during the month of Ramadan and instead observed it during the first ten days of Shawwal.
أن النبي ﷺ ترك الاعتكاف في شهر رمضان حتى اعتكف في العشر الأول من شوال.
Bukhari related it in the Book of Itikaf (2033) via Hammad bin Zayd, and Muslim related it in the Book of Itikaf (1172:6) via Abu Muawiya, both of them from Yahya bin Saeed (who is al-Ansari), who said, Amra bint Abdul-Rahman narrated to me, from Ayesha, who said (and she mentioned it in a long hadith), and the wording here is Muslim's, and it has already been given in full. It did not mention that he fasted, because if he had fasted, the matter would have become well known.