Embryos still metabolize the nutrients delivered by the mother. The metabolism takes place in the cells, including in the developing organs. Metabolism produces waste products that must be removed. The allantois is the structure that removes waste from the embryo.
I'm not sure what you mean by the placenta identifying or differentiating waste materials from the embryo. The waste simply diffuses passively into the mother's blood from the embryo. The mother's excretory systems then handle it.