Praise be to Allah.
The contract between customers and phone companies is a lease or rental contract, so that the customer is the one who is leasing or renting something and the company is the one that is renting it out. The object of the contract is usage of cell phone towers through which the customer is able to avail himself of the services he requires, for communication and other purposes.
The lease or rent is paid in advance by means of prepaid phone cards, or it is paid later on receipt of the invoice.
The credit that the customer has represents the right to usage which became his after buying that right from the company.
On the basis of this lease or rental contract, the customer became the owner of usage or benefit, which is in the form of credit on the card, just as the company became the owner of the fee paid, because it is a contract of exchange.
As this benefit and usage now belongs to the customer, he has the right to dispose of it either by using it himself or by selling it, if there is no condition [in the contract] to restrict that.
Based on that:
Buying some goods from stores with part of his credit on the phone card comes under the heading of buying items in return for benefit or usage, which is permissible and there is nothing wrong with it. There is no stipulation that sales should only be for cash; rather sales may be for cash or for other benefits or other items.
If the phone company charges a fee for this service, there is nothing wrong with that, because it is like a fee for offering the service of transferring usage or benefit from the customer to the shopkeeper, and it is the same whether the transfer is made in the form of credit or cash.
And Allah knows best.