On a crypto exchange, I transferred 1 ether from my account with let's say wallet A to my friend's wallet B. When I searched for my friend's wallet B on etherscan.io to see the transaction, the sender address belonged to crypto exchange's wallet C and not my wallet A. Why do the exchanges do not make the transaction directly from my wallet A to wallet B?
Exchanges do not store your ethers on multiple accounts. They have a few with a lot of ethers like kraken and the amount of ether you got are stored in some "tradionnal" databases.
This way buying and selling can be done almost instantly without having to write on the blockchains which is :
- Longer than modifing datas on some MongoDB for instance
- less expensive because they do not pay gas.
The address you have on your exchange is used to received funds but in your case I bet your exchange couldn't know both addresses belong to them so they transferred your ethers throught the blockchain.
I hope I answered your question :)