Hi,
lookups are based on linking record field. so, new record must contain links in respective field. That should be set up in the process creating new records in a table. Value must be based on a PRIMARY field of Table B.
If it's not apply to your case, you need to set up automation for that. For example, when record matches condition (some ID is not empty, linked field is empty), update linked field with 'some ID'.