Thanks, this is indeed what I was looking for, I just cannot replicate it on mtcars$cyl, I do not know why (maybe class of variable is problematic?)
I also found by chance a similar working solution, which is below:
library(tidyverse)
xx <- as_vector(mtcars[,2])
ggplot()+
aes(x=factor(xx))+
geom_bar()+
geom_text(aes(label=after_stat(count)),vjust=-0.2, stat='count', color="black", size=3.5)
I do not yet know why as.vector does not work but as_vector does, though. 
Maybe because my data is a tibble, whereas mtcars is a data.frame...