You are using the wrong format for year.
‘YYYY’ is the week year, you need to use ‘yyyy’ which is the year for the current datetime.
formatDateTime([%CurrentDateTime%],'yyyy');
Behind the scenes Mendix is using Java’s SimpleDateFormat, more details on the formatting string can be found in its documentation.
https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/text/SimpleDateFormat.html
Hope this helps