This is what you're trying to make it look like underneath your sink. This is what I did to mine to run the water line to my dishwasher after I discovered the direct line to it had broken off inside the wall.
If you just have one line for the cold water with no diverted routes, you'll need to buy about a foot of the same size copper tubing and a tee joint. Here's a before and after (crudely) of what you're trying to do....
What you want to be sure of is that the supply line you add on to go to the washer (the flexible silver colored lines on this picture) has a cap at the end of it that fits the connection on the back of the washer. You'll need a line that looks like these.....
And they come in every length from 4 inches to 8 feet, so make sure you buy one longer than what you will need, just to make sure you have enough to work with. Also, make sure the end with the metal nut that you screw down is the right size for the valve you buy, because those come in a dozen sizes too.
Before you do any of this, you're going to want to locate the water cutoff valve for your main water supply. The easiest way to do this is to see if your water heater has a valce on each line coming off of it. If it does, turn them both off right at the tank. If not, you'll have to go out in the yard and locate the oval shaped metal plate, then open it up and turn ogg the valve with a water key. They sell them for $5-$10 at any hardware store. It looks like this....
After you turn the water off, turn on your sink faucet and let it run until water isn't flowing anymore.
If you're working with copper lines, you'll want to buy a copper tube cutter like this......
They are very easy to use, under $10, but very easy to screw things up if used incorrectly. The best way to do it is to tighten a little bit at a time. You slip it over the copper pipe, and turn the knob on the cutter just until it pushes against the copper slightly, then spin the cutter around the pipe a few times. After that, tighten it a little more, and do the same thing. The key is to only tighten it slightly each time. if you tighten it too hard, you'll bend the pipe and be screwed. Just be gentle with it, it doesn't require force for this thing to cut through the pipe.
Once you've cut through the pipe, clean the end of the pipe off with a wire brush or this ($2-$3)....
After that, connecting the diverter is most easily done by braising it on. Some people try to wet weld, solder, all other goofy methods, but braising is the easiest, cheapest and most effective way to do it. To do that, you'll need any size torch (no need for the big ones, but the butane lighter ones are garbage and won't work), and some copper braising rods (which are also only a few dollars)....
Light the torch, do not aim at wood or drywall, or electrical connections, hoses, etc. and heat the metal where the valve is on the copper pipe. After 15 seconds or so, while keeping the heat on the metal, stick the end of the braising rod onto the gap all the way around the joint between the pipe and valve. The braising rod will melt, and fill in the gap, just work it all the way around the pipe until you've gotten it all. These braising rods look like they're turning to a water liquidity, but you don't need a lot, it fills in the gap very effectively.
After that's done and you run your water line from the valve to the washer, turn your new valve on, and turn your water supply back on and run your sink faucet for a minute to work out the air bubbles, then you're good to go. Check for leaks. If there are none, awesome. If there is one, don't fret it. Any small leak can be sealed with this special tape they make just for that. I don't know what it's called, but it's black, looks kinda like masking tape, and it feels like rubber. Just wrap that around it tightly, and it will seal any small leak fully for 15 years or more. If it's a larger leak, just turn the water off again, and try braising on some more of the braising rod to seal it, and you'll be good to go. The good thing is, I've never seen one leak, even from someone on their first attempt, so don't be hung up on worrying about the leak potential, because it's highly unlikely.
If you need to know anything else, I'll be more than happy to walk you through it, just let me know. The most important thing to remember, is when you buy the water line and the diverter/valve, make sure the end of the hose with the nut fits the connector on the valve. Nothing's worse than multiple trips due to mismatching sizes.