Yes you can! Ricotta is a unique fresh cheese that doesn't melt when heated, but it's totally fine to heat it up. In this recipe, it's lightly heated by the pasta and pasta water.