There is quite a lot of software needed to navigate directories and files of a SD-card.
You may look up a documentation of the filestructure on Wikipedia.
Then there is also the details of how to initialize and communicate with the card.
A SD-card is made to communicate using either a 4 bit parallel interface,
or as a backup protocol, using ordinary SDI with one input, one output and one clock line.
There is free documentation of the SDI interface on the website of SD-card Association,
look for simplified specifications.
The full specification of all details including the 4-bit interface is only available to those members of SD-card Association that pay fees.
Fortunately, other people have done it before.
FatFs by ELM-Chan is good, you may see documentation and download software from his website:http://elm-chan.org/fsw/ff/00index_e.html
There is also a version of the same software wrapped as a library in MCC,
that comes together with SDI driver routines for MSSP peripheral in the PIC18.
Your PIC18F4550 is quite ancient, and is not supported by MCC directly.
You may try to create a MPLAB project for PIC18F45K50,
and run MCC for that, to create code for MSSP peripheral using SPI,
and MCC File system library.
With MCC File System library version 1.0
you may also want to use MCC Foundation Services library version v0.1.34 from the downloads archive.
I have not actually tried it.