DDNS gives a name to an IP Address.

Given that you want to connect to the WAN Ip Address (the IP Address given by the internet provider) you need to setup the DDNS on the main router for the entire building.

If you were to setup DDNS on your 2nd local router, the following scenario would happen.

[Internet] 
  ⬇
[Main Router] Wan IP: 123.45.67.89, LAN range: 192.168.10.x
  ⬇
[second router] WAN IP: 192.168.10.1, LAN range: 192.168.0.x
  ⬇
[Raspberry PI] LAN IP: 192.168.0.79

The above is just an example.

Internet provides IP 123.45.67.89, so the main router will have its WAN addres the same. It creates its own network in the range 192.168.10.x.

Lets assume the secound router gets 192.168.10.51 assigned, and it sees the router as 192.168.10.1, then 192.168.10.1 would be the WAN IP address the router would see. Given that this is not accessible to the public having your DDNS setup on your router would be pointless.

Once DDNS is set on the main router, port forwarding needs to be adressed as follows:

The correct port would be opened from Main Router to IP of second router, secound router to IP of Raspberry PI.