Ask functional, as there are Customizing options for assignment and automatic postings, so check transaction SM30 on view V_T163K or SPRO "Maintain Account Assignment Categories" in "Purchasing". For automatic account origin, check transaction OMWB or SPRO "Configure Automatic Postings" in "Valuation and Account Assignment".
Regards,
Raymonds