First off i imagine you have the replacement tail lights, if not you need to acquire said lights before removal of stock tail lights. approach the rear of the truck from the the back, you should see the rear window. lean forward and look in at one of the back corners of the bed. there should be two hex-screw bolts vertical in orientation, one set on each rear corner. they will be on the other side of the tail light. if you can not see the screws i imagine you have some sort of bed liner, if it is plastic i recommend removal to ease instillation. remove hex-screw bolts of tail lights with PROPER screw driver or metric wrench. negating to do this will result in a stripped bolt. If you cant figure out how to remove the tail lights by looking at them i imagine you will have a very difficult time extracting a stripped bolt.
On the rear of the removed tail light you will see several wires attached to plastic housings, these ( the plastic housings) can be removed by twisting counter-clockwise, only a quarter to half turn is needed. mark with tape on each wire you removed which one it is or where it goes, a simple numbered sequence, "1" being the top most and "2" being the one after that and so on, as to not confuse re-instillation which is pretty impossible as they are different sizes. note any non-functioning bulbs and try to get them before you re-install. replace wires into new tail lights, this time turning plastic bulb housings clockwise until secure, be careful to not over tighten as the bulb housings are plastic and become brittle over time. Repeat on other side.
To reinstall simply mount tail light where it looks like it should fit and look on the inside of the bed at the bolt holes, shifting may be needed to align brackets with hole. Replace bolts. do not over tighten! after complete re-assembly run a light test on every bulb by actuating brakes, blinkers, back up lights... if one is out remove light assembly and find the bad bulb, take it with you when you go to buy a new as to not purchase the wrong one.
congratulations you can now graduate the 8th grade