The general form of the LOAD command was LOAD"(argument)",n,(0 or 1)
(argument) could be: a program name, the $ character meaning "the directory", or the asterisk meaning "the very first file you find". there were other fine refinements to this syntax for special uses.
n, the first number, was the device number. As others have said, default value of 1 was the tape drive, 4 was printer, 8 was the default floppy drive, and 9-14 were alternative drive numbers. The device number was hardware-encoded on the printed circuit board in the device. For example, for the 1571 floppy drive units, you could find instructions to cut through a board trace between two points to make the device become number 9 (your second floppy) instead of 8.
0 or 1, the second number, was the "secondary address" used to code certain actions. In the case of a floppy disk LOAD command, "0" (default if omitted) meant "Load to the "standard" address for programs, which was something like 1024, and then return to the BASIC screen prompt to wait for the next command entry. "1" in this place meant: Load to the specific starting point this file came from in the first place (which was encoded at the start of the file) and then execute a RUN command. The RUN command, by default, always executed from the address specified in a particular RAM location, and by default was the "standard" program stating point. But you could set up a program with a different beginning point specified at this memory location, and then use this loading mode to load that data into that location as part of the load. The included immediate RUN command then looked at that location, jumped to that address, and ran. That was how auto-running programs were executed.
So LOAD"$",8
LIST
was two separate BASIC commands. They meant Load the Directory file from device 8 and return to command prompt (1st line), then execute the LIST command which displayed that "program" on the screen. The format of the data looked internally like a program file, but displayed as a readable directory listing.
LOAD"*",8,1
meant Load the first file name you find from device 8, beginning at the location specified at the start of the file, and execute immediately from the location you find in the fixed location (I cannot remember exactly where) that points to the machine-language start point.
LOAD"*"
meant load the first file you find from the (unspecified default device) tape drive into the "normal" location and return to the command prompt for further instructions.
LOAD"*",1,1
meant (similar to absolute load-and-run from floppy disk) load the first file you find from device 1 (Tape drive) to the address it specifies, then execute beginning at the address found in (that special location I cannot remember).
On the tape drive you had to insert the tape, position it to just before the start of the file you wanted, execute the command on the computer keyboard / screen, then push the tape drive's PLAY button to start it up. The screen would go blank while it searched the tape data stream, pause briefly to display the file name it found, then blank out again as it loaded the file. When it finished loading the file the tape drive would stop (you could push its STOP button them) and the screen would come back on until some further action was taken.
All of the peripherals uses the unique C64 serial bus. It was adapted from the Commodore PET parallel bus, which in turn really was an IEEE parallel bus widely used by Hewlett-Packard and other manufacturers as a general data communication bus for lab instruments. But the C64 bus was a serial version of that with many fewer wires in the cable, configured to hook up in a daisy-chain manner. All such C64 peripherals had two bus sockets (interchangeable) so you just ran cords from one device to the next and they all shared the common bus, each device having its own hard-coded device address.