Asking for a type of guitar by musical style is completely legitimate. Ask for a heavy-metal guitar, and the salesperson nods knowingly and leads you to the corner of the store with all the scary-looking stuff. If you request a jazz guitar, you and the salesperson trundle off in a different direction. Note the variety in shape and style.

Now, some musical styles do share guitar models. You can play both blues and rock, for example, with equal success on a Fender Stratocaster (or Strat, for short). And a Gibson Les Paul is just as capable of playing a wailing lead as a Strat. (As a rule, however, the tone of a Les Paul is going to be fatter and less jangly than that of a Strat.)
Making your own kind of music on the guitar of your choice is part of the fun.
Following are some popular music styles and classic guitars that many people associate with those styles. (Although many of these models are beyond the price range of a first-time buyer, familiarity with them will help you associate models with styles and vice versa. Often, lower-priced guitars are based on the higher-end iconic models.) This list is by no means exhaustive but does include recognized standard-bearers of the respective genres:
Acoustic blues: National Steel, Gibson J-200
Bluegrass: Martin Dreadnought, Taylor Dreadnought, Collings Dreadnought, Santa Cruz Dreadnought, Gallagher Dreadnought
Classical: Ramirez, Hopf, Khono, Humphrey, Hernandez, Alvarez
Country: Fender Telecaster, Gretsch 6120, Fender Stratocaster
Electric blues: Gibson ES-355, Fender Telecaster, Fender Stratocaster, Gibson Les Paul
Folk: Dreadnoughts and Grand Concerts by Martin, Taylor, Collings, Larrivée, Lowden, Yamaha, Alvarez, Epiphone, Ibanez, and Guild; Gibson J-200; Ovation Adamas
Heavy metal: Gibson Explorer, Flying V, and SG; Fender Stratocaster; Dean; Ibanez Iceman; Charvel San Dimas; Jackson Soloist
Jazz: Gibson ES-175, Super 400 L-5, and Johnny Smith; archtops by D’Angelico, D’Aquisto, and Benedetto; Epiphone Emperor Regent; Ibanez signature models
New age, new acoustic: Taylor Grand Concert, Ovation Balladeer, Takamine nylon-electric
R&B: Fender Stratocaster, Gibson ES-335
Rock: Fender Stratocaster, Gibson Les Paul and SG, Ibanez RG and signature series, Paul Reed Smith, Tom Anderson
Although the preceding list contains guitars that people generally associate with given styles, don’t let that limit your creativity. Play the music you want to play on the guitar you want to play it on, no matter what some chart tells you. These guitars are all super sweet, and the price tag reflects the quality as well as the heritage of these guitars.