"There was a billion and a half dollars that was reprogramed", Shanahan said. "Some of it did come from money we were saving, or whatever terminology you want to use, from Afghanistan".
READ MORE: DoD: US Army Engineers Issue $789Mln Contract for Mexico Border Wall Replacement
Pentagon spokesperson Tom Crosson said in a statement on Friday that the Defence Department was drawing $1.5 billion from a variety of sources within the department including "cost savings, programmatic changes and revised requirements".
The funds will be used to replace 78.25 miles of border fencing in the states of Arizona and Texas, the spokesman added.
Shanahan said that he would not be reprogramming any more funds for the border wall. He added that US military readiness was not impacted by the relocation of funds for the fence on the US southern border.
Later on Friday, Shanahan received a letter from ten Democratic senators objecting to the transfer of $1.5 billion internally within the Defence Department to pay for accelerated construction work on the border wall.
"In addition to the unilateral process being used for the second time in two months, we have concerns that this reprogramming comes at the expense of the readiness of the [US] Armed Forces", the letter said on Friday.
READ MORE: Pentagon Authorizes $1 Billion for Trump's Border Wall — Reports
The lawmakers said they are dismayed that the DoD chose to prioritize a political campaign promise over the disaster relief needs of US service members.
The senators also accused Shanahan of ignoring decades of precedent by carrying out a funding transfer without consulting Congress.
The US president has said the wall is needed to prevent criminals and drugs from pouring into the United States. In March, the Pentagon said it identified $12.8 billion in possible funding that could be used to fulfill Trump's call to construct the border wall.