One way to approach this would be to add a salesMonth column to your data frame using the floor_date function from lubridate. Then you can use dplyr to group by the salesMonth and summarize that variable with sum.
Here's a simple using a data.frame I constructed called dailySales:
library(dplyr)
library(lubridate)
dailySales <- data.frame(
saleDate = as.Date(c("2020-01-10", "2020-01-12", "2020-01-12", "2020-01-15", "2020-02-10", "2020-02-25")),
saleAmount = c(100, 100, 200, 100, 50, 100)
)
dailySales <- dailySales %>%
mutate(month = floor_date(dailySales$saleDate, "month"))
dailySales %>%
group_by(month) %>%
summarize(total = sum(saleAmount))