Assuming Windows >= 10:
+ R, intl.cpl
, Enter
doing this:

- Restarting system.
See here/Thank You!
Then (after Restart) we try this in VS Code:
public class Test {
public static void main(String[] args) throws UnsupportedEncodingException {
System.out.println("1: Tiếng Việt có dấu");
try ( PrintWriter consoleOut = new PrintWriter(new OutputStreamWriter(System.out, StandardCharsets.UTF_8))) {
consoleOut.println("2: Tiếng Việt có dấu");
}
}
}
See also/Thank You!
(Ensuring):

See Also.
... we get (Run Java, default shell, pwsh.7.2.0 in my case):
PowerShell 7.2.0
Copyright (c) Microsoft Corporation.
https://aka.ms/powershell
Type 'help' to get help.
PS C:\DEV\projects\test> & 'C:\Program Files\Java\jdk1.8.0_311\bin\java.exe' '-cp' 'C:\Users\xerx\AppData\Local\Temp\cp_16pw9c0xw9lhctexolmzuqrp.jar' 'Test'
1: Ti?ng Vi?t c d?u
2: Tiếng Việt có dấu
PS C:\DEV\projects\test>
... but also switching to cmd.exe
:
Microsoft Windows [Version 10.0.19044.1348]
(c) Microsoft Corporation. Alle Rechte vorbehalten.
C:\DEV\projects\test>java -cp C:\Users\xerx\AppData\Local\Temp\cp_16pw9c0xw9lhctexolmzuqrp.jar Test
1: Ti?ng Vi?t c d?u
2: Tiếng Việt có dấu
GitBash?!? - "Null Problemo":
picard@enterprise MINGW64 /c/DEV/projects/test (main)
$ java -cp ~/AppData/Local/Temp/cp_16pw9c0xw9lhctexolmzuqrp.jar Test
1: Ti?ng Vi?t c d?u
2: Tiếng Việt có dấu
So the problem is rather not in VS Code or Java, but more "general"/historic/"proprietary" (see the threads linked + What encoding/code page is cmd.exe using? + https://www.google.com/search?q=windows+console+encoding :)
Because in Ubuntu (wsl) Shell:
picard@enterprise:/mnt/c/DEV/projects/test$ java -cp ./build/classes/java/main/ Test
1: Tiếng Việt có dấu
2: Tiếng Việt có dấu
!! ;)