In this case, "cuánto" is part of the phrase "cuánto cuestan" and refers to the amount of money, not to the number of grapes, so gender and number agreement with "uvas" is not needed. But if you were asking about the quantity of the grapes themselves, you would indeed write: "¿Cuántas uvas hay?"