Wire transfers normally run through either the Fedwire system or the Clearing House Interbank Payments System (CHIPS). The process generally works like this:
You approach a bank or other financial institution and ask to transfer money. You give the bank a certain code, either an international bank account number or one of several other standards, which informs the bank where to send the money.
The bank sends a message through a system like Fedwire to the receiving bank, along with settlement instructions.
This is where the process can get a bit tricky. For the wire transfer to work, the banks must have reciprocal accounts with each other, or the sending bank must send the money to a bank that does have such an account with the receiver. If the sending bank sends the money to a third-party bank, the transaction is settled between them, and the money is then sent to the receiving bank from the third-party bank. This last transaction may be a wire transfer, ACH transfer, etc.
The Federal Reserve fits into this because many banks hold accounts for this purpose with the Federal Reserve. This allows them to use the Fed as the third-party bank referred to above. Interestingly enough, this is one of the significant ways in which the Fed makes a profit, because it, along with every other bank and routing agent in the process, collects a miniscule fee on this process.
You'll often find sources that state that Fedwire is only for transferring large transactions; while this is technically correct, it's important to understand that financial institutions don't settle every wire transfer or payment immediately. Although the orders are put in immediately, the financial institutions settle their transactions in bulk at the end of the business day, and even then they normally only settle the difference. So, if Chase owes Bank of America $1M, and Bank of America owes Chase $750K, they don't send these as two transactions; Chase simply credits BAC $250K.
You didn't specifically ask about ACH transfers, which as littleadv pointed out, are different from wire transfers, but since ACH transfers can often form a part of the whole process, I'll explain that process too. ACH is a payment processing system that works through the Federal Reserve system, among others. The Federal Reserve (through the Fedline and FedACH systems) is by far the largest payment processor.
The physical cash itself isn't transferred; in simple terms, the money is transferred through the ACH system between the accounts each bank maintains at the Federal Reserve.
Here is a simple example of how the process works (I'm summarizing the example from Wikipedia). Let's say that Bob has an account with Chase and wants to get his paycheck from his employer, Stack Exchange, directly deposited into this account. Assume that Stack Exchange uses Bank of America as their bank.
Bob, the receiver, fills out a direct deposit authorization form and gives it to his employer, called the originator.
Once the originator has the authorization, they create an entry with an Originating Depository Financial Institution, which acts as a middleman between a payment processor (like the Federal Reserve) and the originator. The ODFI ensures that the transaction complies with the relevant regulations. In this example, Bank of America is the ODFI.
Bank of America (the ODFI) converts the transaction request into an ACH entry and submits it, through an ACH operator, to the Receiving Depository Financial Institution (RDFI), which in this case is Chase bank. Chase credits (deposits) the paycheck in Bob's account.
The Federal Reserve fits into all of this in several ways. Through systems like Fedline and FedACH, the Fed acts as an ACH operator, and the banks themselves also maintain accounts at the Federal Reserve, so it's the institution that actually performs the settling of accounts between banks.