Try this:
library(data.table)
dt1 = data.table(ID = c(2000,2001,2002,2003), A = c(2,2,1,6), B = c(3,7,8,2), C = c(4,2,5,3))
dt2 = data.table(ID = c(2001, 2003), B = c(0,0))
dt1 = merge(dt1,dt2,by = c("ID"),all.x = TRUE)
which gives us
ID A B.x C B.y
1: 2000 2 3 4 NA
2: 2001 2 7 2 0
3: 2002 1 8 5 NA
4: 2003 6 2 3 0
Then, I'm not sure if you had a typo and really wanted to reset B, but if you did want to reset C to the B.y run this
dt1$C = ifelse(!is.na(dt1$B.y),dt1$B,dt1$C)
Which will give us:
ID A B.x C B.y
1: 2000 2 3 4 NA
2: 2001 2 7 0 0
3: 2002 1 8 5 NA
4: 2003 6 2 0 0
Then, just drop B.y and change B.x back to B
dt1[,B.y:= NULL]
colnames(dt1)[3] = "B"
ID A B C
1: 2000 2 3 4
2: 2001 2 7 0
3: 2002 1 8 5
4: 2003 6 2 0