The two Raka'aa that the Prophet (صلى الله عليه وسلم) continously prayed after Asr were from his special traits. This is proven in the authentic hadeeth in which Umm Salama said: I heard Allah's Messenger forbade praying after Asr then I saw him praying the two rakaa after asr. So, she sent a servant to ask him on her tongue: I heard you forbidden people to pray after ast then I see you praying it. He replied with : I had people over and they kept me busy so that I missed the two Rakaat after Dhuhr so what I prayed were those.
Narrated Kuraib: I was sent to Aisha by Ibn Abbas, Al-Miswar bin Makhrama and 'Abdur-Rahman bin Azhar . they told me to greet her on their behalf and to ask her about the offering of the two Rakat after the 'Asr prayer and to say to her, "We were informed that you offer those two Rakat and we were told that the Prophet had forbidden offering them." Ibn Abbas said, "I along with 'Umar bin Al-Khattab used to beat the people whenever they offered them." I went to Aisha and told her that message. 'Aisha said, "Go and ask Um Salama about them." So I returned and informed them about her statement. they then told me to go to Um Salama with the same question with which t sent me to 'Aisha. Um Salama replied, "I heard the Prophet forbidding them. Later I saw him offering them immediately after he prayed the 'Asr prayer. He then entered my house at a time when some of the Ansari women from the tribe of Bani Haram were sitting with me, so I sent my slave girl to him having said to her, 'Stand beside him and tell him that Um Salama says to you, "O Allah's Apostle! I have heard you forbidding the offering of these (two Rakat after the 'Asr prayer) but I have seen you offering them." If he waves his hand then wait for him.' the slave girl did that. the Prophet beckoned her with his hand and she waited for him. When he had finished the prayer he said, "O daughter of Bani Umaiya! You have asked me about the two Rakat after the 'Asr prayer. the people of the tribe of 'Abdul-Qais came to me and made me busy and I could not offer the two Rakat after the Zuhr prayer. these (two Rakat that I have just prayed) are for those (missed) ones. (Sahih Bukhari; Book #22, Hadith #325)
Above hadeeth clears that at that time the hadeeth of preventing praying was already established and when the prophet prayed them the prevention was still affective and the reason for praying is not to allow it at all and not to obrgate it as well. The reason why he prayed them originally to make up the Sunnah of after Dhuhr that he missed due to visitors as been proven in the authentic Hadeeth from the narration of Umm Salamah.
The reason why he continoued praying them is because it is known that the Prophet (صلى الله عليه وسلم) whenever he does an act he keeps doing it as known in the authentic hadeeths.
Narrated 'Aisha: By Allah, Who took away the Prophet. The Prophet never missed them (two Rakat) after the 'Asr prayer till he met Allah and he did not meet Allah till it became heavy for him to pray while standing so he used to offer most of the prayers while sitting. (She meant the two Rakat after Asr) He used to pray them in the house and never prayed them in the mosque lest it might be hard for his followers and he loved what was easy for them . (Sahih Bukhari; Book #10, Hadith #564)
“He remained in Mecca for ten years," The nation is agreed that he, pbuh, stayed in Mecca for thirteen years, therefore one could say that those who narrated ten years, rounded down and left off mention of the additional three, or one could say that the narration of those who mention thirteen years is stronger. "And in Madınah for ten years," meaning after the Hijrah. He, pbuh, remained there for ten years and there is no difference concerning this. He remained there until the people entered into the religion in droves, until Allah perfected the religion for him and his nation and completed His favour upon them.
"Allah caused him to pass away at the turn of his sixtieth year," This implies that he passed away at the age of sixty, however the strongest opinion is that he was sixty-three and it is said sixty-five. These ages are reconciled by stating that those who stated sixty-five included the year of his birth and death. Those who mentioned sixty-three did not and those who mentioned sixty rounded down. This point is not contradicted by the statement ‘turn of his sixtieth year’ because what is meant here is the beginning of his sixties.
"And there were not to be found [as much as] twenty white hairs on his head and beard," Rather there were less as proven by the narration of ibn Sa`d [from Anas (RA)], ‘There were only seventeen white hairs on his head and beard.’ There is no contradiction between this and the report of ibn `Umar (RA), ‘He had approximately twenty white hairs’ [al-Bayhaqı] because this just talks about an approximation.