Not to defend corporations and banks, but it’s kinda true. When you swipe your debit card, your bank allocates those funds for that transaction, but whoever you’re paying doesn’t actually have it yet, and your bank hasn’t sent it yet. That’s just the way the banking system works. It can take days for them to actually get your money, depending on weekends, holidays, etc. When you request a refund, the process just goes in reverse.
Think of it like a check. If I write a check and give it to someone, I write the amount in the check register as if it’s spent, but until that person takes my check to the bank, they don’t actually have the money yet.