1) This uses only base R and does not use any regular expressions. It assumes that (1) there are only letters and spaces before the date as that is the case in the question but that could easily be relaxed, if necessary, by adding additional characters to lets and (2) the date is in standard Date format. chartr translates the ith character in its first argument to the ith character in its second replacing each letter with a space. Then use as.Date. Note that as.Date ignores junk at the end so it is ok if additional characters not in lets follow the date.
x <- "X2018-01-11_poland"
lets <- paste(letters, collapse = "")
as.Date(chartr(lets, strrep(" ", nchar(lets)), tolower(x)))
## [1] "2018-01-11"
2) If we knew that the string always starts with X and the Date appears right after it then we can just specify the prefix in the as.Date format string. It also does not use any regular expressions and only uses base R.
as.Date(x, "X%Y-%m-%d")
## [1] "2018-01-11"
3) If you are willing to compromise and use a very simple regular expression -- here \D matches any non-digit and backslashes must be doubled within quotes. gsub removes any such character.
as.Date(gsub("\\D", "", x), "%Y%m%d")
## [1] "2018-01-11"