This easy crowd-pleaser works equally well as a quick dinner or a party appetizer. Small shrimp are less expensive and almost preferable here. If you use larger ones, consider cutting them in half lengthwise either before or after cooking (it only takes a minute) so they'll be flatter and better spread throughout the quesadilla.
Heat the oil in a 12-inch nonstick skillet over medium-high. Add garlic and cook, stirring, for 30 seconds, then add shrimp. Sprinkle with plenty of salt and pepper. Cook, flipping once, until just shy of opaque in the center -- a couple minutes total, depending on size. Add spinach and another sprinkle of salt and cook until wilted. Set aside.
Arrange four of the tortillas on a work surface. Using half the cheese, sprinkle each tortilla evenly, leaving a slight border around the edge to account for melting. Top each tortilla evenly with beans and the shrimp and spinach mixture. Sprinkle with remaining cheese, then top each with one of the four remaining tortillas.
Wipe the pan clean and place over medium heat. One at a time, cook quesadillas until tortillas are browned in spots and cheese is fully melted, flipping once.
To serve, cut into wedges. Stir a tablespoon of water into the sour cream and drizzle over quesadillas. Sprinkle with pickled onions if using.