I'm not sure I understand what it is you're trying to achieve here but if all you need is a unique identifier for each individual (i.e. row) within your last subset and don't care about the household ID, could you not just do something like:
library(tidyverse)
last_subset <-
data.frame(stringsAsFactors = FALSE,
Var1 = c("ID1", "ID1", "ID1", "ID2", "ID2", "ID3", "ID3", "ID3", "ID3"),
Var2 = c("y", "n", "n", "n", "n", "y", "y", "y", "y"),
Var3 = c(1999, 1990, 1997, 1989, 1999, 1910, 1954, 1999, 1977),
Var4 = c(1, 8, 11, 3, 6, 9, 17, 7, 17)
)
last_subset %>%
# maintain HouseholdID if important
rename(HouseholdID = Var1) %>%
# Add unique ID for each individual/row
mutate(Var1 = paste0('ID',row_number()))
#> HouseholdID Var2 Var3 Var4 Var1
#> 1 ID1 y 1999 1 ID1
#> 2 ID1 n 1990 8 ID2
#> 3 ID1 n 1997 11 ID3
#> 4 ID2 n 1989 3 ID4
#> 5 ID2 n 1999 6 ID5
#> 6 ID3 y 1910 9 ID6
#> 7 ID3 y 1954 17 ID7
#> 8 ID3 y 1999 7 ID8
#> 9 ID3 y 1977 17 ID9
Created on 2019-05-16 by the reprex package (v0.2.1)